<!-- 
RSS generated by JIRA (8.20.10#820010-sha1:ace47f9899e9ee25d7157d59aa17ab06aee30d3d) at Wed Feb 07 20:54:15 UTC 2024

It is possible to restrict the fields that are returned in this document by specifying the 'field' parameter in your request.
For example, to request only the issue key and summary append 'field=key&field=summary' to the URL of your request.
-->
<rss version="0.92" >
<channel>
    <title>OpenDaylight JIRA</title>
    <link>https://jira.opendaylight.org</link>
    <description>This file is an XML representation of an issue</description>
    <language>en-us</language>    <build-info>
        <version>8.20.10</version>
        <build-number>820010</build-number>
        <build-date>22-06-2022</build-date>
    </build-info>


<item>
            <title>[YANGTOOLS-766] yang-data-codec-gson: compressed instance-identifier codec</title>
                <link>https://jira.opendaylight.org/browse/YANGTOOLS-766</link>
                <project id="10188" key="YANGTOOLS">yangtools</project>
                    <description>&lt;p&gt;There is a slight difference between how instance-identifiers are encoded in &lt;a href=&quot;https://tools.ietf.org/html/draft-lhotka-netmod-yang-json-02&quot; class=&quot;external-link&quot; target=&quot;_blank&quot; rel=&quot;nofollow noopener&quot;&gt;https://tools.ietf.org/html/draft-lhotka-netmod-yang-json-02&lt;/a&gt; (used by draft-bierman-netconf-restconf-02) and &lt;a href=&quot;https://tools.ietf.org/html/rfc7951&quot; class=&quot;external-link&quot; target=&quot;_blank&quot; rel=&quot;nofollow noopener&quot;&gt;https://tools.ietf.org/html/rfc7951&lt;/a&gt; (used by RFC8040).&lt;/p&gt;

&lt;p&gt;For RFC8040 we need to use a different JSON codec to handle prefixes.&lt;/p&gt;

&lt;p&gt;While we are in the area, I suspect key encoding does not work correctly (for both XML and JSON) with respect to complex types &amp;#8211; i.e. when we are encoding an instance identifier which uses one of:&lt;/p&gt;
&lt;ul class=&quot;alternate&quot; type=&quot;square&quot;&gt;
	&lt;li&gt;empty&lt;/li&gt;
	&lt;li&gt;identityref&lt;/li&gt;
	&lt;li&gt;instance-identifier&lt;br/&gt;
as type of a key leaf.&lt;/li&gt;
&lt;/ul&gt;
</description>
                <environment>&lt;p&gt;Operating System: All&lt;br/&gt;
Platform: All&lt;/p&gt;</environment>
        <key id="23186">YANGTOOLS-766</key>
            <summary>yang-data-codec-gson: compressed instance-identifier codec</summary>
                <type id="10104" iconUrl="https://jira.opendaylight.org/secure/viewavatar?size=xsmall&amp;avatarId=10303&amp;avatarType=issuetype">Bug</type>
                                                <status id="5" iconUrl="https://jira.opendaylight.org/images/icons/statuses/resolved.png" description="A resolution has been taken, and it is awaiting verification by reporter. From here issues are either reopened, or are closed.">Resolved</status>
                    <statusCategory id="3" key="done" colorName="green"/>
                                    <resolution id="10000">Done</resolution>
                                        <assignee username="rovarga">Robert Varga</assignee>
                                    <reporter username="rovarga">Robert Varga</reporter>
                        <labels>
                    </labels>
                <created>Mon, 27 Mar 2017 09:20:03 +0000</created>
                <updated>Sun, 10 Apr 2022 18:35:58 +0000</updated>
                            <resolved>Thu, 28 Dec 2017 15:34:39 +0000</resolved>
                                    <version>2.0.0</version>
                    <version>1.2.1</version>
                                    <fixVersion>1.2.2</fixVersion>
                    <fixVersion>2.0.1</fixVersion>
                                        <due></due>
                            <votes>0</votes>
                                    <watches>2</watches>
                                                                                                                <comments>
                            <comment id="44393" author="ifoltin" created="Thu, 30 Mar 2017 13:55:03 +0000"  >&lt;p&gt;I wrote a bunch of unit tests - &lt;a href=&quot;https://git.opendaylight.org/gerrit/#/c/54106/&quot; class=&quot;external-link&quot; target=&quot;_blank&quot; rel=&quot;nofollow noopener&quot;&gt;https://git.opendaylight.org/gerrit/#/c/54106/&lt;/a&gt;&lt;br/&gt;
Here&apos;s what I found out:&lt;/p&gt;

&lt;p&gt;JSON parsing:&lt;/p&gt;

&lt;p&gt;Currently, an instance-identifier value must have all its node-identifiers prefixed to be parsed without failing. Thus, if we want to follow the rules defined in RFC7951, we&apos;ll have to modify the JSON instance-identifier codec so that values like this can be parsed:&lt;br/&gt;
/ietf-interfaces:interfaces/interface&lt;span class=&quot;error&quot;&gt;&amp;#91;name=&amp;#39;eth0&amp;#39;&amp;#93;&lt;/span&gt;/ietf-ip:ipv4/ip&lt;/p&gt;

&lt;p&gt;An instance-identifier which has a list with a key of type empty in its path - this does not work because the key value (in JSON it&apos;s &lt;span class=&quot;error&quot;&gt;&amp;#91;null&amp;#93;&lt;/span&gt;) is deserialized to null which leads to a NPE when inserting it into a key-value map here: XpathStringParsingPathArgumentBuilder.java:166&lt;/p&gt;

&lt;p&gt;An instance-identifier which has a list with a key of type identityref in its path - this works whether the key value contains a prefix or not.&lt;/p&gt;

&lt;p&gt;An instance-identifier which has a list with a key of type instance-identifier in its path - this works only when the key value contains prefixes.&lt;/p&gt;

&lt;p&gt;XML parsing:&lt;/p&gt;

&lt;p&gt;An instance-identifier which has a list with a key of type empty in its path - this does not work because the key value (in XML it&apos;s an empty/self-closed element) is deserialized to null which leads to a NPE when inserting it into key-value map here: XpathStringParsingPathArgumentBuilder.java:166&lt;/p&gt;

&lt;p&gt;An instance-identifier which has a list with a key of type identityref in its path - this works whether the key value contains a prefix or not.&lt;/p&gt;

&lt;p&gt;An instance-identifier which has a list with a key of type instance-identifier in its path - this works only when the key value contains prefixes.&lt;/p&gt;</comment>
                            <comment id="60563" author="rovarga" created="Tue, 26 Dec 2017 11:43:40 +0000"  >&lt;p&gt;Since the above analysis was done we have moved a bit. empty leaves are now properly represented with a non-null Empty object, allowing them to be used in keys. &lt;a href=&quot;https://jira.opendaylight.org/browse/YANGTOOLS-678&quot; title=&quot;[Yang 1.1] Allow type &amp;quot;empty&amp;quot; in a key&quot; class=&quot;issue-link&quot; data-issue-key=&quot;YANGTOOLS-678&quot;&gt;&lt;del&gt;YANGTOOLS-678&lt;/del&gt;&lt;/a&gt; is taking care of enabling the @Ignore&apos;d JSON test.&lt;/p&gt;

&lt;p&gt;&#160;&lt;/p&gt;

&lt;p&gt;This leaves this issue to deal with the original problem, which is YangInstanceIdentifier parsing/emission without repeating prefixes. The JSON parser API change to enable users to select proper JSONCodecFactory is at &lt;a href=&quot;https://git.opendaylight.org/gerrit/66765&quot; class=&quot;external-link&quot; target=&quot;_blank&quot; rel=&quot;nofollow noopener&quot;&gt;https://git.opendaylight.org/gerrit/66765&lt;/a&gt;.&lt;/p&gt;</comment>
                            <comment id="60564" author="rovarga" created="Tue, 26 Dec 2017 17:47:44 +0000"  >&lt;p&gt;As it turns out, this issue affects both parsing and emission of YangInstanceIdentifier, as RFC7951 explicitly forbids the use of prefixes when the subsequent node identifier has the same namespace.&lt;/p&gt;</comment>
                            <comment id="60565" author="rovarga" created="Tue, 26 Dec 2017 18:04:30 +0000"  >&lt;p&gt;At any rate, the next step is to wire a slightly different version of XpathStringParsingPathArgumentBuilder into RFC7951, one that is memoizing last used prefix (or even resulting QNameModule) when parsing an argument, but not when parsing predicates.&lt;/p&gt;</comment>
                            <comment id="60567" author="rovarga" created="Wed, 27 Dec 2017 08:19:11 +0000"  >&lt;p&gt;Support for parsing RFC7951 instance identifiers: &lt;a href=&quot;https://git.opendaylight.org/gerrit/66772&quot; class=&quot;external-link&quot; target=&quot;_blank&quot; rel=&quot;nofollow noopener&quot;&gt;https://git.opendaylight.org/gerrit/66772&lt;/a&gt;&lt;/p&gt;</comment>
                            <comment id="60568" author="rovarga" created="Wed, 27 Dec 2017 11:54:41 +0000"  >&lt;p&gt;Nitrogen cherry-picks:&lt;/p&gt;

&lt;p&gt;&lt;a href=&quot;https://git.opendaylight.org/gerrit/66773&quot; class=&quot;external-link&quot; target=&quot;_blank&quot; rel=&quot;nofollow noopener&quot;&gt;https://git.opendaylight.org/gerrit/66773&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;&lt;a href=&quot;https://git.opendaylight.org/gerrit/66774&quot; class=&quot;external-link&quot; target=&quot;_blank&quot; rel=&quot;nofollow noopener&quot;&gt;https://git.opendaylight.org/gerrit/66774&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;&#160;&lt;/p&gt;</comment>
                    </comments>
                <issuelinks>
                            <issuelinktype id="10000">
                    <name>Blocks</name>
                                            <outwardlinks description="blocks">
                                        <issuelink>
            <issuekey id="29026">NETCONF-494</issuekey>
        </issuelink>
                            </outwardlinks>
                                                                <inwardlinks description="is blocked by">
                                        <issuelink>
            <issuekey id="23178">YANGTOOLS-758</issuekey>
        </issuelink>
            <issuelink>
            <issuekey id="23179">YANGTOOLS-759</issuekey>
        </issuelink>
                            </inwardlinks>
                                    </issuelinktype>
                            <issuelinktype id="10002">
                    <name>Duplicate</name>
                                                                <inwardlinks description="is duplicated by">
                                        <issuelink>
            <issuekey id="23202">YANGTOOLS-782</issuekey>
        </issuelink>
                            </inwardlinks>
                                    </issuelinktype>
                            <issuelinktype id="10003">
                    <name>Relates</name>
                                            <outwardlinks description="relates to">
                                        <issuelink>
            <issuekey id="23098">YANGTOOLS-678</issuekey>
        </issuelink>
                            </outwardlinks>
                                                        </issuelinktype>
                    </issuelinks>
                <attachments>
                    </attachments>
                <subtasks>
                    </subtasks>
                <customfields>
                                                                            <customfield id="customfield_11400" key="com.atlassian.jira.plugins.jira-development-integration-plugin:devsummary">
                        <customfieldname>Development</customfieldname>
                        <customfieldvalues>
                            
                        </customfieldvalues>
                    </customfield>
                                                                                                                        <customfield id="customfield_10208" key="com.atlassian.jira.plugin.system.customfieldtypes:textfield">
                        <customfieldname>External issue ID</customfieldname>
                        <customfieldvalues>
                            <customfieldvalue>8083</customfieldvalue>

                        </customfieldvalues>
                    </customfield>
                                                                <customfield id="customfield_10201" key="com.atlassian.jira.plugin.system.customfieldtypes:url">
                        <customfieldname>External issue URL</customfieldname>
                        <customfieldvalues>
                            <customfieldvalue><![CDATA[https://bugs.opendaylight.org/show_bug.cgi?id=8083]]></customfieldvalue>

                        </customfieldvalues>
                    </customfield>
                                                                                            <customfield id="customfield_10206" key="com.atlassian.jira.plugin.system.customfieldtypes:select">
                        <customfieldname>Issue Type</customfieldname>
                        <customfieldvalues>
                                <customfieldvalue key="10300"><![CDATA[Bug]]></customfieldvalue>

                        </customfieldvalues>
                    </customfield>
                                                                                                                                                                                                                                                                                                                                                                                                                                                                        <customfield id="customfield_10000" key="com.pyxis.greenhopper.jira:gh-lexo-rank">
                        <customfieldname>Rank</customfieldname>
                        <customfieldvalues>
                            <customfieldvalue>0|i02993:</customfieldvalue>

                        </customfieldvalues>
                    </customfield>
                                                                                                                                                                                </customfields>
    </item>
</channel>
</rss>