<!-- 
RSS generated by JIRA (8.20.10#820010-sha1:ace47f9899e9ee25d7157d59aa17ab06aee30d3d) at Wed Feb 07 20:55:54 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-1353] Yang models using &quot;ietf-yang-schema-mount&quot; mount-point are not supported in ODL </title>
                <link>https://jira.opendaylight.org/browse/YANGTOOLS-1353</link>
                <project id="10188" key="YANGTOOLS">yangtools</project>
                    <description>&lt;p&gt;The Broadband Forum has a YANG 1.1 model called bbf-obbaa-network-manager.yang model which uses a &quot;root&quot; yang-schema-mount. That is, the &quot;root&quot; can point to any other YANG model.&#160;&lt;/p&gt;

&lt;p&gt;Example:&#160;&lt;/p&gt;
&lt;div class=&quot;code panel&quot; style=&quot;border-width: 1px;&quot;&gt;&lt;div class=&quot;codeContent panelContent&quot;&gt;
&lt;pre class=&quot;code-java&quot;&gt;
container network-manager {
        description
          &lt;span class=&quot;code-quote&quot;&gt;&quot;Infomations about the devices and adapters managed by BAA&quot;&lt;/span&gt;;
        container managed-devices {
            description
              &lt;span class=&quot;code-quote&quot;&gt;&quot;The managed devices and device communication settings.&quot;&lt;/span&gt;;
            list device {
                key &lt;span class=&quot;code-quote&quot;&gt;&quot;name&quot;&lt;/span&gt;;
                description
                    &lt;span class=&quot;code-quote&quot;&gt;&quot;The device list which managed by BAA.&quot;&lt;/span&gt;;
                leaf name {
                    type string;
                    description
                      &lt;span class=&quot;code-quote&quot;&gt;&quot;The name of device.&quot;&lt;/span&gt;;
                }
                container device-management {
                    description
                        &lt;span class=&quot;code-quote&quot;&gt;&quot;The management informations &lt;span class=&quot;code-keyword&quot;&gt;for&lt;/span&gt; a device.&quot;&lt;/span&gt;;
                    uses management-grouping;
                }
                container device-notification {
                    description
                        &lt;span class=&quot;code-quote&quot;&gt;&quot;The notification triggered when the device state changed.&quot;&lt;/span&gt;;
                    uses notification-grouping;
                }
                container root {
                    yangmnt:mount-point &lt;span class=&quot;code-quote&quot;&gt;&quot;root&quot;&lt;/span&gt;;
                    description
                      &lt;span class=&quot;code-quote&quot;&gt;&quot;Root &lt;span class=&quot;code-keyword&quot;&gt;for&lt;/span&gt; models supported per device.&quot;&lt;/span&gt;;
                }
            }
        }
       ...

&lt;/pre&gt;
&lt;/div&gt;&lt;/div&gt;
&lt;p&gt;In this yang model, there is a container called &quot;root&quot; which points to the root models of any yang model.&#160; The &quot;yangmnt&quot; is:&lt;/p&gt;

&lt;p&gt;&#160;&lt;/p&gt;
&lt;div class=&quot;code panel&quot; style=&quot;border-width: 1px;&quot;&gt;&lt;div class=&quot;codeContent panelContent&quot;&gt;
&lt;pre class=&quot;code-java&quot;&gt;
&lt;span class=&quot;code-keyword&quot;&gt;import&lt;/span&gt; ietf-yang-schema-mount {
        prefix yangmnt;
    }

&lt;/pre&gt;
&lt;/div&gt;&lt;/div&gt;
&lt;p&gt;&#160;&lt;/p&gt;

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

&lt;p&gt;Usage of this can be seen in the following notification - A system may have a &quot;netconf-config-change&quot; notification for example that has this &quot;network-manager&quot; yang underneath it:&lt;/p&gt;
&lt;div class=&quot;code panel&quot; style=&quot;border-width: 1px;&quot;&gt;&lt;div class=&quot;codeContent panelContent&quot;&gt;
&lt;pre class=&quot;code-java&quot;&gt;
&amp;lt;notification xmlns=&lt;span class=&quot;code-quote&quot;&gt;&quot;urn:ietf:params:xml:ns:netconf:notification:1.0&quot;&lt;/span&gt;&amp;gt;
  &amp;lt;eventTime&amp;gt;2021-08-17T18:35:46+00:00&amp;lt;/eventTime&amp;gt;
  &amp;lt;netconf-config-change xmlns=&lt;span class=&quot;code-quote&quot;&gt;&quot;urn:ietf:params:xml:ns:yang:ietf-netconf-notifications&quot;&lt;/span&gt;&amp;gt;
    &amp;lt;datastore&amp;gt;running&amp;lt;/datastore&amp;gt;
      &amp;lt;changed-by&amp;gt;
        &amp;lt;username&amp;gt;PMA_USER&amp;lt;/username&amp;gt;
        &amp;lt;session-id&amp;gt;1&amp;lt;/session-id&amp;gt;
        &amp;lt;source-host&amp;gt;172.16.0.2&amp;lt;/source-host&amp;gt;
      &amp;lt;/changed-by&amp;gt;
      &amp;lt;edit&amp;gt;
        &amp;lt;target xmlns:baa-network-manager=&lt;span class=&quot;code-quote&quot;&gt;&quot;urn:bbf:yang:obbaa:network-manager&quot;&lt;/span&gt;
              xmlns:bbf-xpongemtcont=&lt;span class=&quot;code-quote&quot;&gt;&quot;urn:bbf:yang:bbf-xpongemtcont&quot;&lt;/span&gt;&amp;gt;/baa-network-manager:network-manager/baa-network-manager:managed-devices/baa-network-manager:device[baa-network-manager:name=&lt;span class=&quot;code-quote&quot;&gt;&apos;myDevice&apos;&lt;/span&gt;]/baa-network-manager:root/bbf-xpongemtcont:xpongemtcont/bbf-xpongemtcont:tconts/bbf-xpongemtcont:tcont[bbf-xpongemtcont:name=&lt;span class=&quot;code-quote&quot;&gt;&apos;tcont_ont1_2_0&apos;&lt;/span&gt;]&amp;lt;/target&amp;gt;
        &amp;lt;operation&amp;gt;create&amp;lt;/operation&amp;gt;
      &amp;lt;/edit&amp;gt;
   &amp;lt;/netconf-config-change&amp;gt;
&amp;lt;/notification&amp;gt;

&lt;/pre&gt;
&lt;/div&gt;&lt;/div&gt;
&lt;p&gt;&lt;tt&gt;&#160;&lt;/tt&gt;&lt;/p&gt;

&lt;p&gt;&#160;Is we look at the &quot;target&quot; part of the message above, we see that it is using the network manager yang, and also the bbf-xpongemtcont...&lt;/p&gt;
&lt;div class=&quot;code panel&quot; style=&quot;border-width: 1px;&quot;&gt;&lt;div class=&quot;codeContent panelContent&quot;&gt;
&lt;pre class=&quot;code-java&quot;&gt;
/baa-network-manager:root/bbf-xpongemtcont:xpongemtcont/
&lt;/pre&gt;
&lt;/div&gt;&lt;/div&gt;
&lt;p&gt;The transition from &quot;root&quot; to an actual yang model (bbf-xpongemtcont) is not supported. ODL will throw away this notification because it cannot parse this.&lt;/p&gt;

&lt;p&gt;In the following file:&lt;br/&gt;
 yang/yang-data-util/src/main/java/org/opendaylight/yangtools/yang/data/util/XpathStringParsingPathArgumentBuilder.java&#160; (yang tools 6.0.5)&lt;/p&gt;
&lt;div class=&quot;code panel&quot; style=&quot;border-width: 1px;&quot;&gt;&lt;div class=&quot;codeContent panelContent&quot;&gt;
&lt;pre class=&quot;code-java&quot;&gt;
  XpathStringParsingPathArgumentBuilder(&lt;span class=&quot;code-keyword&quot;&gt;final&lt;/span&gt; AbstractStringInstanceIdentifierCodec codec, &lt;span class=&quot;code-keyword&quot;&gt;final&lt;/span&gt; &lt;span class=&quot;code-object&quot;&gt;String&lt;/span&gt; data) {
        &lt;span class=&quot;code-keyword&quot;&gt;this&lt;/span&gt;.codec = requireNonNull(codec);
        &lt;span class=&quot;code-keyword&quot;&gt;this&lt;/span&gt;.data = requireNonNull(data);
        &lt;span class=&quot;code-keyword&quot;&gt;this&lt;/span&gt;.current = codec.getDataContextTree().getRoot(); &lt;span class=&quot;code-comment&quot;&gt;// RSM This line
&lt;/span&gt;        &lt;span class=&quot;code-keyword&quot;&gt;this&lt;/span&gt;.offset = 0;
    }
&lt;/pre&gt;
&lt;/div&gt;&lt;/div&gt;
&lt;p&gt;&#160;The &quot;getDataContextTree&quot; will be relative to the &quot;bbf-obba-network-manager&quot; yang when parsing. When it comes time to find the &quot;bbf-xpongemtcont&quot; model, it will return null causing the notification to be thrown away as it does not exist in the context tree.&lt;/p&gt;

&lt;p&gt;Also, the yangtool issue here can be hacked to work allowing the notification up. But then there is a second issue where a notification listener for &quot;netconf change notifications&quot; will not get a proper JAVA object because of the &quot;root schema mount&quot;.&#160;&lt;/p&gt;

&lt;p&gt;For example -&#160;&lt;/p&gt;

&lt;p&gt;org.opendaylight.mdsal.binding.dom.adapter.BindingDOMNotificationListenerAdapter&lt;/p&gt;

&lt;p&gt;(mdsal-binding-dom-adaptor version 7.0.6)&lt;/p&gt;
&lt;div class=&quot;code panel&quot; style=&quot;border-width: 1px;&quot;&gt;&lt;div class=&quot;codeContent panelContent&quot;&gt;
&lt;pre class=&quot;code-java&quot;&gt;
@Override
&lt;span class=&quot;code-keyword&quot;&gt;public&lt;/span&gt; void onNotification(&lt;span class=&quot;code-keyword&quot;&gt;final&lt;/span&gt; DOMNotification notification) {
        &lt;span class=&quot;code-keyword&quot;&gt;final&lt;/span&gt; Notification baNotification = deserialize(notification);
        &lt;span class=&quot;code-keyword&quot;&gt;final&lt;/span&gt; QName notificationQName = notification.getType().lastNodeIdentifier();
        getInvoker(notification.getType()).invokeNotification(delegate, notificationQName, baNotification);
}
&lt;/pre&gt;
&lt;/div&gt;&lt;/div&gt;
&lt;p&gt;When the deserialize is complete, the baNotificaiton is not completely mapped to an object due to the &quot;root&quot; mount.&#160;&lt;/p&gt;

&lt;p&gt;More information can be added to this issue if required. Wondering if this is a known issue already related to YANG 1.1 and possibly part of 1.1 support in progress.&lt;/p&gt;

&lt;p&gt;&#160;&lt;/p&gt;</description>
                <environment></environment>
        <key id="34680">YANGTOOLS-1353</key>
            <summary>Yang models using &quot;ietf-yang-schema-mount&quot; mount-point are not supported in ODL </summary>
                <type id="10104" iconUrl="https://jira.opendaylight.org/secure/viewavatar?size=xsmall&amp;avatarId=10303&amp;avatarType=issuetype">Bug</type>
                                            <priority id="3" iconUrl="https://jira.opendaylight.org/images/icons/priorities/major.svg">Medium</priority>
                        <status id="1" iconUrl="https://jira.opendaylight.org/images/icons/statuses/open.png" description="The issue is open and ready for the assignee to start work on it.">Open</status>
                    <statusCategory id="2" key="new" colorName="blue-gray"/>
                                    <resolution id="-1">Unresolved</resolution>
                                        <assignee username="-1">Unassigned</assignee>
                                    <reporter username="rmagaldi">Robert Magaldi</reporter>
                        <labels>
                    </labels>
                <created>Tue, 19 Oct 2021 20:05:50 +0000</created>
                <updated>Wed, 9 Feb 2022 21:47:47 +0000</updated>
                                                                                <due></due>
                            <votes>0</votes>
                                    <watches>2</watches>
                                                                                                                <comments>
                            <comment id="69900" author="rovarga" created="Mon, 25 Oct 2021 09:51:54 +0000"  >&lt;p&gt;So YANG Schema Mount support is not thoroughly integrated in the stack, so depending on how the request is constructed, we may be losing some information we have.&lt;/p&gt;

&lt;p&gt;A secondary problem here is that a schema mount can mean two different things. Can you post the contents of /ietf-yang-schema-mount:schema-mounts operational datastore? &lt;/p&gt;</comment>
                            <comment id="70502" author="JIRAUSER13915" created="Tue, 1 Feb 2022 14:45:33 +0000"  >&lt;p&gt;Trying to clarify the issue...&lt;/p&gt;

&lt;p&gt;I believe there are no contents for the /ietf-yang-schema-mount:schema-mounts operational data store. We are not storing anything in this case.&#160;&lt;/p&gt;

&lt;p&gt;I think the issue is more general - I have attached a file &quot;bbf-obba-network-manager@2021-02-01.yang&quot;.&#160; This is an Broadband forum network manager yang file which contains a &quot;root&quot; mount - meaning it points to any other yang model.&#160;&lt;/p&gt;

&lt;p&gt;Inside this yang for example there is this:&lt;/p&gt;

&lt;p&gt;&lt;span class=&quot;image-wrap&quot; style=&quot;&quot;&gt;&lt;img src=&quot;https://jira.opendaylight.org/secure/attachment/17305/17305_image-2022-02-01-09-34-47-260.png&quot; style=&quot;border: 0px solid black&quot; /&gt;&lt;/span&gt;&lt;/p&gt;

&lt;p&gt;The issue is that &quot;container root&quot; is meant to point to any other YANG model.&#160;&lt;/p&gt;

&lt;p&gt;If a device &quot;X&quot; is mounted onto ODL, a controller talking to ODL could send a &quot;bbf-network-manager&quot; request through ODL to the mounted device. The YANG could have a &quot;root&quot; container which points to any other YANG model for example.&#160;&lt;/p&gt;

&lt;p&gt;This&#160;issue deals with notifications in particular - where a&#160; notification comes into ODL for a BBF NETCONF device and is pointing to another YANG model using the &quot;root&quot; container:&lt;br/&gt;
&amp;lt;target xmlns:baa-network-manager=&quot;urn:bbf:yang:obbaa:network-manager&quot;              xmlns:bbf-xpongemtcont=&quot;urn:bbf:yang:bbf-xpongemtcont&quot;&amp;gt;/baa-network-manager:network-manager/baa-network-manager:managed-devices/baa-network-manager:device&lt;span class=&quot;error&quot;&gt;&amp;#91;baa-network-manager:name=&amp;#39;myDevice&amp;#39;&amp;#93;&lt;/span&gt;/baa-network-manager:root/bbf-xpongemtcont:xpongemtcont/bbf-xpongemtcont:tconts/bbf-xpongemtcont:tcont&lt;span class=&quot;error&quot;&gt;&amp;#91;bbf-xpongemtcont:name=&amp;#39;tcont_ont1_2_0&amp;#39;&amp;#93;&lt;/span&gt;&amp;lt;/target&amp;gt;&lt;br/&gt;
For example&#160; - this target is using the &quot;root&quot; concept to point to another yang model called &quot;bbf-xpongemtcont&quot;&lt;/p&gt;

&lt;p&gt;BBF is using Yang 1.1 models, and this use of &quot;root&quot; to point to any other YANG model is the issue.&#160;&lt;/p&gt;</comment>
                            <comment id="70503" author="rovarga" created="Tue, 1 Feb 2022 15:22:47 +0000"  >&lt;p&gt;Understood, but please note that in order to under stand what the device means when it says &quot;baa-network-manager:root/&quot; it must also populate the appropriate data in its operational datastore, as specified by &lt;a href=&quot;https://datatracker.ietf.org/doc/html/rfc8528#section-3.3&quot; class=&quot;external-link&quot; target=&quot;_blank&quot; rel=&quot;nofollow noopener&quot;&gt;RFC8528&lt;/a&gt;, specifically /schema-mounts/mount-points[module=&apos;baa-network-manager&apos;, label=&apos;root&apos;. If it does not, the device is broken and there is nothing we can do simply because the device is violating the RFC and we have absolutely no idea how to interpret that mount-point instance.&lt;/p&gt;

&lt;p&gt;Without seeing the contents of that list entry, I cannot begin to speculate as to what to do with this issue.&lt;/p&gt;</comment>
                            <comment id="70529" author="JIRAUSER13915" created="Wed, 9 Feb 2022 21:42:00 +0000"  >&lt;p&gt;Sorry.. when I tried to get information I didn&apos;t have access to to a real device (simulator only). &lt;br/&gt;
Here is some information&lt;br/&gt;
curl -X GET &quot;http://10.184.144.176:8181/restconf/data/network-topology:network-topology/topology=topology-netconf/node=Lowell-vOLT1/yang-ext:mount/ietf-yang-schema-mount:schema-mounts?content=nonconfig&quot; -H &quot;accept: application/xml&quot;&lt;/p&gt;

&lt;p&gt;&amp;lt;schema-mounts xmlns=&quot;urn:ietf:params:xml:ns:yang:ietf-yang-schema-mount&quot;&amp;gt;&lt;br/&gt;
  &amp;lt;mount-point&amp;gt;&lt;/p&gt;



&lt;p&gt;    &amp;lt;module&amp;gt;network-manager&amp;lt;/module&amp;gt;&lt;br/&gt;
    &amp;lt;label&amp;gt;root&amp;lt;/label&amp;gt;&lt;br/&gt;
    &amp;lt;config&amp;gt;true&amp;lt;/config&amp;gt;&lt;br/&gt;
  &amp;lt;/mount-point&amp;gt;&lt;br/&gt;
  &amp;lt;namespace&amp;gt;&lt;br/&gt;
    &amp;lt;prefix&amp;gt;network-manager&amp;lt;/prefix&amp;gt;&lt;br/&gt;
    &amp;lt;uri&amp;gt;urn:bbf:yang:obbaa:network-manager&amp;lt;/uri&amp;gt;&lt;br/&gt;
  &amp;lt;/namespace&amp;gt;&lt;br/&gt;
&amp;lt;/schema-mounts&amp;gt;&lt;/p&gt;

&lt;p&gt;Guessing here.. This problem may be related to the yang tool file &quot;XpathStringParsingPathArgumentBuilder.java&quot; under yang/yang-data-util/src/main/java/org/opendaylight/yangtools... &lt;/p&gt;

&lt;p&gt;It seems when parsing a &quot;root&quot;, ODL doesn&apos;t go back to its original list of schema context to see if it can figure it out.  &lt;/p&gt;</comment>
                    </comments>
                    <attachments>
                            <attachment id="17304" name="bbf-obbaa-network-manager@2021-02-01.yang" size="24796" author="rmagaldi" created="Tue, 1 Feb 2022 14:30:45 +0000"/>
                            <attachment id="17305" name="image-2022-02-01-09-34-47-260.png" size="10306" author="rmagaldi" created="Tue, 1 Feb 2022 14:34:48 +0000"/>
                    </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_10000" key="com.pyxis.greenhopper.jira:gh-lexo-rank">
                        <customfieldname>Rank</customfieldname>
                        <customfieldvalues>
                            <customfieldvalue>0|i040bz:</customfieldvalue>

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