[NETCONF-134] NullPointerException when entering data with undefined element at first level Created: 28/Jan/16 Updated: 15/Mar/19 Resolved: 24/Feb/16 |
|
| Status: | Resolved |
| Project: | netconf |
| Component/s: | netconf |
| Affects Version/s: | None |
| Fix Version/s: | None |
| Type: | Bug | ||
| Reporter: | Jozef Behran | Assignee: | Tomas Cere |
| Resolution: | Done | Votes: | 0 |
| Labels: | None | ||
| Remaining Estimate: | Not Specified | ||
| Time Spent: | Not Specified | ||
| Original Estimate: | Not Specified | ||
| Environment: |
Operating System: All |
||
| Attachments: |
|
| External issue ID: | 5125 |
| Description |
|
Tested on: stable/beryllium 1. Make sure odl-clustering-test-app is NOT installed. <rpc message-id="2" a="64" xmlns="urn:ietf:params:xml:ns:netconf:base:1.0"> 3. You will get the following response: <rpc-reply a="64" message-id="2" xmlns="urn:ietf:params:xml:ns:netconf:base:1.0"> I expected something along the lines of "Element 'cars' not found" or "No model for element 'cars' found" or even "Unknown child element(s) ... 'cars' ...". Or something mentioning "people" or "car-people" or even their namespaces (urn:opendaylight:params:xml:ns:yang:controller:config:sal-clustering-it: {car|people|car-people}). |
| Comments |
| Comment by Jozef Behran [ 28/Jan/16 ] |
|
Attachment karaf.log.xz has been added with description: Compressed log from the test run exhibiting the bug |
| Comment by Jozef Behran [ 28/Jan/16 ] |
|
I suspect the problem is caused by the element in the nonexistent namespace being in the first level (directly contained in <config>). I came to this conclusion after realizing that this request works (with the odl-clustering-test-app feature installed) (note the bogus element is contained within a valid element): <rpc message-id="2" xmlns="urn:ietf:params:xml:ns:netconf:base:1.0"> which gives this reply: <rpc-reply message-id="2" xmlns="urn:ietf:params:xml:ns:netconf:base:1.0"> (note that the <error> element mentions both, "urn:this:is:in:a:nonexistent:namespace" and "does-not-exist") while this request (note that the bogus element is directly under <config>): <rpc message-id="2" xmlns="urn:ietf:params:xml:ns:netconf:base:1.0"> results in "java.lang.NullPointerException" in the <error> tag. |
| Comment by Jozef Behran [ 28/Jan/16 ] |
|
Added a testcase against this into the MD-SAL suite: https://git.opendaylight.org/gerrit/33685 |
| Comment by Tomas Cere [ 02/Feb/16 ] |