[NETCONF-685] Apidoc explorer is not able to list mountpoint content (RFC8040) Created: 13/May/20  Updated: 14/Jul/20  Resolved: 03/Jun/20

Status: Resolved
Project: netconf
Component/s: restconf-nb
Affects Version/s: Magnesium, Sodium SR2
Fix Version/s: Aluminium, Sodium SR3, Magnesium SR2

Type: Bug Priority: Low
Reporter: Richard Kosegi Assignee: Richard Kosegi
Resolution: Done Votes: 0
Labels: None
Remaining Estimate: Not Specified
Time Spent: Not Specified
Original Estimate: Not Specified
Environment:

Apidocs explorer (RFC8040), Sodium-SR2


Issue Links:
Duplicate
duplicates NETCONF-703 Apidocs does not work in Aluminum Verified

 Description   

When trying to load content of mountpoint using rfc8040 apidoc explorer (http://localhost:8181/apidoc/18/explorer/index.html), only "500 : Undefined" error is shown to user.

Quick look at karaf log reveals NPE:

15:33:26.027 WARN [qtp1851346207-76] /apidoc/18/apis/mounts/1
javax.servlet.ServletException: javax.servlet.ServletException: java.lang.NumberFormatException: null
	at org.ops4j.pax.web.service.jetty.internal.JettyServerHandlerCollection.handle(JettyServerHandlerCollection.java:88) ~[?:?]
	at org.eclipse.jetty.server.handler.HandlerWrapper.handle(HandlerWrapper.java:132) ~[151:org.eclipse.jetty.server:9.4.18.v20190429]
	at org.eclipse.jetty.server.Server.handle(Server.java:505) ~[151:org.eclipse.jetty.server:9.4.18.v20190429]
...
Caused by: java.lang.NumberFormatException: null
	at java.lang.Integer.parseInt(Integer.java:542) ~[?:?]
	at java.lang.Integer.parseInt(Integer.java:615) ~[?:?]
	at org.opendaylight.netconf.sal.rest.doc.impl.ApiDocServiceImpl.getMountRootDoc(ApiDocServiceImpl.java:128) ~[?:?]
	at sun.reflect.GeneratedMethodAccessor96.invoke(Unknown Source) ~[?:?]
	at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) ~[?:?]

Looks like UI does not propagate query parameters correctly to REST endpoint.



 Comments   
Comment by Luis Gomez [ 14/Jul/20 ]

This was fixed and test added in NETCONF-703

Generated at Wed Feb 07 20:15:38 UTC 2024 using Jira 8.20.10#820010-sha1:ace47f9899e9ee25d7157d59aa17ab06aee30d3d.