Uploaded image for project: 'netconf'
  1. netconf
  2. NETCONF-856

Integrate message-id and other NETCONF attributes

    XMLWordPrintable

Details

    • Task
    • Status: Confirmed
    • Medium
    • Resolution: Unresolved
    • None
    • None
    • netconf
    • None

    Description

      The following splat is currently present when we first connect to a NETCONF device:

      2022-01-12T13:01:03,758 | INFO  | globalWorkerGroup-3-1 | StreamWriterFacade               | 322 - org.opendaylight.yangtools.yang-data-codec-xml - 7.0.9 | Encountered annotation message-id not bound to module. Please examine the call stack and fix this warning by defining a proper YANG annotation to cover it
      java.lang.Throwable: Call stack
      	at org.opendaylight.yangtools.yang.data.codec.xml.StreamWriterFacade.warnLegacyAttribute(StreamWriterFacade.java:307) [bundleFile:?]
      	at org.opendaylight.yangtools.yang.data.codec.xml.XmlParserStream.getElementAttributes(XmlParserStream.java:356) [bundleFile:?]
      	at org.opendaylight.yangtools.yang.data.codec.xml.XmlParserStream.read(XmlParserStream.java:429) [bundleFile:?]
      	at org.opendaylight.yangtools.yang.data.codec.xml.XmlParserStream.parse(XmlParserStream.java:311) [bundleFile:?]
      	at org.opendaylight.yangtools.yang.data.codec.xml.XmlParserStream.traverse(XmlParserStream.java:338) [bundleFile:?]
      	at org.opendaylight.netconf.sal.connect.netconf.schema.mapping.NetconfMessageTransformer.parseResult(NetconfMessageTransformer.java:466) [bundleFile:?]
      	at org.opendaylight.netconf.sal.connect.netconf.schema.mapping.NetconfMessageTransformer.toRpcResult(NetconfMessageTransformer.java:427) [bundleFile:?]
      	at org.opendaylight.netconf.sal.connect.netconf.schema.mapping.NetconfMessageTransformer.toRpcResult(NetconfMessageTransformer.java:97) [bundleFile:?]
      	at org.opendaylight.netconf.sal.connect.netconf.sal.NetconfDeviceRpc$1.onSuccess(NetconfDeviceRpc.java:62) [bundleFile:?]
      	at org.opendaylight.netconf.sal.connect.netconf.sal.NetconfDeviceRpc$1.onSuccess(NetconfDeviceRpc.java:58) [bundleFile:?]
      	at com.google.common.util.concurrent.Futures$CallbackListener.run(Futures.java:1080) [bundleFile:?]
      	at com.google.common.util.concurrent.DirectExecutor.execute(DirectExecutor.java:30) [bundleFile:?]
      	at com.google.common.util.concurrent.AbstractFuture.executeListener(AbstractFuture.java:1213) [bundleFile:?]
      	at com.google.common.util.concurrent.AbstractFuture.complete(AbstractFuture.java:983) [bundleFile:?]
      	at com.google.common.util.concurrent.AbstractFuture.set(AbstractFuture.java:746) [bundleFile:?]
      	at org.opendaylight.netconf.sal.connect.netconf.listener.UncancellableFuture.set(UncancellableFuture.java:45) [bundleFile:?]
      	at org.opendaylight.netconf.sal.connect.netconf.listener.NetconfDeviceCommunicator.processMessage(NetconfDeviceCommunicator.java:353) [bundleFile:?]
      	at org.opendaylight.netconf.sal.connect.netconf.listener.NetconfDeviceCommunicator.onMessage(NetconfDeviceCommunicator.java:283) [bundleFile:?]
      	at org.opendaylight.netconf.sal.connect.netconf.listener.NetconfDeviceCommunicator.onMessage(NetconfDeviceCommunicator.java:50) [bundleFile:?]
      	at org.opendaylight.netconf.nettyutil.AbstractNetconfSession.handleMessage(AbstractNetconfSession.java:65) [bundleFile:?]
      	at org.opendaylight.netconf.nettyutil.AbstractNetconfSession.channelRead0(AbstractNetconfSession.java:186) [bundleFile:?]
      	at io.netty.channel.SimpleChannelInboundHandler.channelRead(SimpleChannelInboundHandler.java:99) [bundleFile:4.1.69.Final]
      	at io.netty.channel.AbstractChannelHandlerContext.invokeChannelRead(AbstractChannelHandlerContext.java:379) [bundleFile:4.1.69.Final]
      	at io.netty.channel.AbstractChannelHandlerContext.invokeChannelRead(AbstractChannelHandlerContext.java:365) [bundleFile:4.1.69.Final]
      	at io.netty.channel.AbstractChannelHandlerContext.fireChannelRead(AbstractChannelHandlerContext.java:357) [bundleFile:4.1.69.Final]
      	at io.netty.handler.codec.ByteToMessageDecoder.fireChannelRead(ByteToMessageDecoder.java:324) [bundleFile:4.1.69.Final]
      	at io.netty.handler.codec.ByteToMessageDecoder.channelRead(ByteToMessageDecoder.java:296) [bundleFile:4.1.69.Final]
      	at io.netty.channel.AbstractChannelHandlerContext.invokeChannelRead(AbstractChannelHandlerContext.java:379) [bundleFile:4.1.69.Final]
      	at io.netty.channel.AbstractChannelHandlerContext.invokeChannelRead(AbstractChannelHandlerContext.java:365) [bundleFile:4.1.69.Final]
      	at io.netty.channel.AbstractChannelHandlerContext.fireChannelRead(AbstractChannelHandlerContext.java:357) [bundleFile:4.1.69.Final]
      	at io.netty.handler.codec.ByteToMessageDecoder.fireChannelRead(ByteToMessageDecoder.java:324) [bundleFile:4.1.69.Final]
      	at io.netty.handler.codec.ByteToMessageDecoder.channelRead(ByteToMessageDecoder.java:296) [bundleFile:4.1.69.Final]
      	at io.netty.channel.AbstractChannelHandlerContext.invokeChannelRead(AbstractChannelHandlerContext.java:379) [bundleFile:4.1.69.Final]
      	at io.netty.channel.AbstractChannelHandlerContext.access$600(AbstractChannelHandlerContext.java:61) [bundleFile:4.1.69.Final]
      	at io.netty.channel.AbstractChannelHandlerContext$7.run(AbstractChannelHandlerContext.java:370) [bundleFile:4.1.69.Final]
      	at io.netty.util.concurrent.AbstractEventExecutor.safeExecute(AbstractEventExecutor.java:164) [bundleFile:4.1.69.Final]
      	at io.netty.util.concurrent.SingleThreadEventExecutor.runAllTasks(SingleThreadEventExecutor.java:469) [bundleFile:4.1.69.Final]
      	at io.netty.channel.nio.NioEventLoop.run(NioEventLoop.java:500) [bundleFile:4.1.69.Final]
      	at io.netty.util.concurrent.SingleThreadEventExecutor$4.run(SingleThreadEventExecutor.java:986) [bundleFile:4.1.69.Final]
      	at io.netty.util.internal.ThreadExecutorMap$2.run(ThreadExecutorMap.java:74) [bundleFile:4.1.69.Final]
      	at io.netty.util.concurrent.FastThreadLocalRunnable.run(FastThreadLocalRunnable.java:30) [bundleFile:4.1.69.Final]
      	at java.lang.Thread.run(Thread.java:829) [?:?]
      

      This is the result of how RFC7952/RFC6241 works in absence of YANGTOOLS-982. The problem here is that the XML parser does not see an RFC7952 annotation definition in YANG world, as NETCONF's model dates back to 2013 when there were no annotations.
      Nevertheless NETCONF defines (through XSD) the possibility of a message-id attribute.

      This warning will go away as soon as ietf-netconf.yang is updates to properly define an annotation for message-id, but until then we need to work this around manually.

      Once YANGTOOLS-982 provides a mechanism for NETCONF code to bind this attribute to a fake annotation, use that mechanism and bind all NETCONF attributes to them.

      Attachments

        Issue Links

          No reviews matched the request. Check your Options in the drop-down menu of this sections header.

          Activity

            People

              Unassigned Unassigned
              rovarga Robert Varga
              Votes:
              0 Vote for this issue
              Watchers:
              1 Start watching this issue

              Dates

                Created:
                Updated: