X-Git-Url: https://git.opendaylight.org/gerrit/gitweb?a=blobdiff_plain;f=opendaylight%2Fmd-sal%2Fsal-rest-connector%2Fsrc%2Fmain%2Fjava%2Forg%2Fopendaylight%2Fcontroller%2Fsal%2Frestconf%2Fimpl%2FControllerContext.java;h=5566f01674a3112e2f0dd09c8287b17a9e0752b4;hb=ddaf5bf1e47671e5e9ddf65e9456b7c582fb381e;hp=8bdf401300e91d4e3a67c7e0e58970e432a1283b;hpb=40c2487f8068ee8ba045798d3be716899c77a6e6;p=controller.git diff --git a/opendaylight/md-sal/sal-rest-connector/src/main/java/org/opendaylight/controller/sal/restconf/impl/ControllerContext.java b/opendaylight/md-sal/sal-rest-connector/src/main/java/org/opendaylight/controller/sal/restconf/impl/ControllerContext.java index 8bdf401300..5566f01674 100644 --- a/opendaylight/md-sal/sal-rest-connector/src/main/java/org/opendaylight/controller/sal/restconf/impl/ControllerContext.java +++ b/opendaylight/md-sal/sal-rest-connector/src/main/java/org/opendaylight/controller/sal/restconf/impl/ControllerContext.java @@ -587,6 +587,15 @@ public class ControllerContext implements SchemaContextListener { } targetNode = findInstanceDataChildByNameAndNamespace(parentNode, nodeName, module.getNamespace()); + + if (targetNode == null && parentNode instanceof Module) { + final RpcDefinition rpc = ControllerContext.getInstance().getRpcDefinition(head); + if (rpc != null) { + return new InstanceIdentifierContext(builder.build(), rpc, mountPoint, + mountPoint != null ? mountPoint.getSchemaContext() : globalSchema); + } + } + if (targetNode == null) { throw new RestconfDocumentedException("URI has bad format. Possible reasons:\n" + " 1. \"" + head + "\" was not found in parent data node.\n" + " 2. \"" + head