Details
Description
When sending the following restconf request to ODL, it looks like the parser is stripping off the second xmlns attribute.
Post request:
<action xmlns="http://tail-f.com/ns/netconf/actions/1.0">
<data>
<hw-module xmlns="http://www.cisco.com/ns/yang/Cisco-IOS-XR-sysadmin-hw-module">
<oper>
<location>
<location>all</location>
<actions>
<reload/>
</actions>
</location>
</oper>
</hw-module>
</data>
</action>
When checking the ODL logs seeing it removes the second xmlns.
request: <rpc message-id="m-1408" xmlns="urn:ietf:params:xml:ns:netconf:base:1.0">
<action xmlns="http://tail-f.com/ns/netconf/actions/1.0">
<data>
<hw-module>
<oper>
<location>
<location>all</location>
<actions>
<reload/>
</actions>
</location>
</oper>
</hw-module>
</data>
</action>
</rpc>
The following raw netconf-yang rpc works:
<rpc message-id="edcfd773-daac-4fdd-9867-053d4742d453" xmlns="urn:ietf:params:xml:ns:netconf:base:1.0">
<data>
<hw-module xmlns="http://www.cisco.com/ns/yang/Cisco-IOS-XR-sysadmin-hw-module">
<oper>
<location>
<location>all</location>
<actions>
<reload/>
</actions>
</location>
</oper>
</hw-module>
</data>
</action>
</rpc>
In the yang file the input rpc action is defined as:
rpc action {
description
"Support Tail-F actions rpc format.";
reference "RFC 6241, Section 7.1";
input
Unknown macro: { anyxml data Unknown macro}}
Attachments
Issue Links
- is duplicated by
-
NETCONF-586 RPC ietf-netconf:edit-config removes device namespaces
-
- Resolved
-
-
YANGTOOLS-864 XmlParserStream.readAnyXmlValue ignores namespaces
-
- Resolved
-
| # | Subject | Branch | Project | Status | CR | V |
|---|---|---|---|---|---|---|
| 78466,5 | Preserve attributes when parsing AnyXml from XML | master | yangtools | Status: MERGED | +2 | +1 |
| 78479,2 | Preserve attributes when parsing AnyXml from XML | v2.0.x | yangtools | Status: MERGED | +2 | +1 |
| 78588,1 | Preserve attributes when parsing AnyXml from XML | v2.0.6.x | yangtools | Status: MERGED | -1 | +1 |