[MDSAL-371] SchemaRootCodecContext doesn't support actions inside list - KeyedListAction Created: 19/Sep/18  Updated: 01/Oct/18  Resolved: 01/Oct/18

Status: Resolved
Project: mdsal
Component/s: None
Affects Version/s: Fluorine
Fix Version/s: 3.0.0, Fluorine SR1

Type: Bug Priority: Medium
Reporter: Anna Bencúrová Assignee: Jakub Toth
Resolution: Done Votes: 0
Labels: None
Remaining Estimate: Not Specified
Time Spent: Not Specified
Original Estimate: Not Specified


 Description   

When the action is inside list, it is not possible to send call to device via netconf. I assume, that there is missing support for KeyedListAction in SchemaRootCodecContext.

The action definition is not found and NullPointerException is produced.

 

Using binding ActionService:

java.lang.NullPointerException
    at org.opendaylight.mdsal.binding.dom.codec.impl.SchemaRootCodecContext.createActionContext(SchemaRootCodecContext.java:209)
    at org.opendaylight.mdsal.binding.dom.codec.impl.SchemaRootCodecContext$2.load(SchemaRootCodecContext.java:65)
    at org.opendaylight.mdsal.binding.dom.codec.impl.SchemaRootCodecContext$2.load(SchemaRootCodecContext.java:62)
    at com.google.common.cache.LocalCache$LoadingValueReference.loadFuture(LocalCache.java:3708)
    at com.google.common.cache.LocalCache$Segment.loadSync(LocalCache.java:2416)
    at com.google.common.cache.LocalCache$Segment.lockedGetOrLoad(LocalCache.java:2299)
    at com.google.common.cache.LocalCache$Segment.get(LocalCache.java:2212)
    at com.google.common.cache.LocalCache.get(LocalCache.java:4147)
    at com.google.common.cache.LocalCache.getOrLoad(LocalCache.java:4151)
    at com.google.common.cache.LocalCache$LocalLoadingCache.get(LocalCache.java:5140)
    at com.google.common.cache.LocalCache$LocalLoadingCache.getUnchecked(LocalCache.java:5146)
    at org.opendaylight.mdsal.binding.dom.codec.impl.SchemaRootCodecContext.getOrRethrow(SchemaRootCodecContext.java:329)
    at org.opendaylight.mdsal.binding.dom.codec.impl.SchemaRootCodecContext.getAction(SchemaRootCodecContext.java:182)
    at org.opendaylight.mdsal.binding.dom.codec.impl.BindingCodecContext.getActionCodec(BindingCodecContext.java:226)
    at org.opendaylight.mdsal.binding.dom.codec.impl.BindingNormalizedNodeCodecRegistry.newActionInputWriter(BindingNormalizedNodeCodecRegistry.java:270)
    at org.opendaylight.mdsal.binding.dom.codec.impl.BindingNormalizedNodeCodecRegistry.lambda$toNormalizedNodeActionInput$1(BindingNormalizedNodeCodecRegistry.java:142)
    at org.opendaylight.mdsal.binding.dom.codec.impl.BindingNormalizedNodeCodecRegistry.serializeDataObject(BindingNormalizedNodeCodecRegistry.java:170)
    at org.opendaylight.mdsal.binding.dom.codec.impl.BindingNormalizedNodeCodecRegistry.toNormalizedNodeActionInput(BindingNormalizedNodeCodecRegistry.java:142)
    at org.opendaylight.mdsal.binding.dom.codec.impl.BindingNormalizedNodeCodecRegistry$LazyActionInputContainerNode.computeContainerNode(BindingNormalizedNodeCodecRegistry.java:376)
    at org.opendaylight.mdsal.binding.dom.codec.impl.BindingNormalizedNodeCodecRegistry$LazyActionInputContainerNode.computeContainerNode(BindingNormalizedNodeCodecRegistry.java:367)
    at org.opendaylight.mdsal.binding.dom.codec.util.AbstractBindingLazyContainerNode.delegate(AbstractBindingLazyContainerNode.java:117)
    at org.opendaylight.mdsal.binding.dom.codec.util.AbstractBindingLazyContainerNode.getValue(AbstractBindingLazyContainerNode.java:85)
    at org.opendaylight.netconf.sal.connect.netconf.util.NetconfMessageTransformUtil.writeNormalizedRpc(NetconfMessageTransformUtil.java:447)
    at org.opendaylight.netconf.sal.connect.netconf.schema.mapping.NetconfMessageTransformer.toActionRequest(NetconfMessageTransformer.java:244)
    at org.opendaylight.netconf.sal.connect.netconf.schema.mapping.NetconfMessageTransformer.toActionRequest(NetconfMessageTransformer.java:74)

... invoke path

 

Also when converting inside netconf device:

Caused by: java.lang.NullPointerException
    at org.opendaylight.mdsal.binding.dom.codec.impl.SchemaRootCodecContext.createActionContext(SchemaRootCodecContext.java:209)
    at org.opendaylight.mdsal.binding.dom.codec.impl.SchemaRootCodecContext$2.load(SchemaRootCodecContext.java:65)
    at org.opendaylight.mdsal.binding.dom.codec.impl.SchemaRootCodecContext$2.load(SchemaRootCodecContext.java:62)
    at com.google.common.cache.LocalCache$LoadingValueReference.loadFuture(LocalCache.java:3708)
    at com.google.common.cache.LocalCache$Segment.loadSync(LocalCache.java:2416)
    at com.google.common.cache.LocalCache$Segment.lockedGetOrLoad(LocalCache.java:2299)
    at com.google.common.cache.LocalCache$Segment.get(LocalCache.java:2212)
    at com.google.common.cache.LocalCache.get(LocalCache.java:4147)
    at com.google.common.cache.LocalCache.getOrLoad(LocalCache.java:4151)
    at com.google.common.cache.LocalCache$LocalLoadingCache.get(LocalCache.java:5140)
    at com.google.common.cache.LocalCache$LocalLoadingCache.getUnchecked(LocalCache.java:5146)
    at org.opendaylight.mdsal.binding.dom.codec.impl.SchemaRootCodecContext.getOrRethrow(SchemaRootCodecContext.java:329)
    at org.opendaylight.mdsal.binding.dom.codec.impl.SchemaRootCodecContext.getAction(SchemaRootCodecContext.java:182)
    at org.opendaylight.mdsal.binding.dom.codec.impl.BindingCodecContext.getActionCodec(BindingCodecContext.java:226)
    at org.opendaylight.mdsal.binding.dom.codec.impl.BindingNormalizedNodeCodecRegistry.fromNormalizedNodeActionInput(BindingNormalizedNodeCodecRegistry.java:240)
    at org.opendaylight.mdsal.binding.dom.adapter.BindingToNormalizedNodeCodec.fromNormalizedNodeActionInput(BindingToNormalizedNodeCodec.java:206)
    at

... execution path


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