[YANGTOOLS-783] Add support for parsing wildcard instance identifiers to JSON codec Created: 07/Jun/17  Updated: 10/Apr/22

Status: Confirmed
Project: yangtools
Component/s: None
Affects Version/s: None
Fix Version/s: None

Type: New Feature
Reporter: Marek Gradzki Assignee: Unassigned
Resolution: Unresolved Votes: 0
Labels: None
Remaining Estimate: Not Specified
Time Spent: Not Specified
Original Estimate: Not Specified
Environment:

Operating System: All
Platform: All



 Description   

While https://tools.ietf.org/html/rfc6020#section-9.13 requires instance identifiers to have keys,
it would be useful to be able to parse unkeyed ids to YII and then II (both support wildcards).

Simplest solution would be to make JSONStringInstanceIdentifierCodec accept
wildcard instance identfiers.

Example use case would be to define processing order for yang nodes in human friendly format, e.g.:

/ietf-interfaces:interfaces/interface -> /v3po:bridge-domains/bridge-domain



 Comments   
Comment by Marek Gradzki [ 07/Jun/17 ]

Would Boron-SR4 be possible provided:

https://git.opendaylight.org/gerrit/#/c/58386/

does the right job?

Comment by Robert Varga [ 07/Jun/17 ]

Right, but where would that be used? Note that wildcards are an accidental feature and we certainly do not want to break compliance here.

Comment by Marek Gradzki [ 08/Jun/17 ]

We need such utility in honeycomb (we want to let users define node processing order via text files).
JSON format is simplest one.

In my opinion this change does not break compliance with RFC, just extends it.

But I agree that perhaps JSONStringInstanceIdentifierCodec is not the best place for adding this functionality.

After closer look at RFC, absolute schema node identifier to wildcard InstanceIdentifier is something we need. And it looks like yangtools provides some utils for parsing them...

Generated at Wed Feb 07 20:54:18 UTC 2024 using Jira 8.20.10#820010-sha1:ace47f9899e9ee25d7157d59aa17ab06aee30d3d.