[YANGTOOLS-808] IllegalArgumentExcetion while transform OpenFlow model normalizednode to Json Created: 24/Aug/17  Updated: 10/Apr/22  Resolved: 20/Feb/18

Status: Resolved
Project: yangtools
Component/s: None
Affects Version/s: 1.0.4
Fix Version/s: None

Type: Bug
Reporter: DongWenying Assignee: Unassigned
Resolution: Cannot Reproduce Votes: 0
Labels: None
Remaining Estimate: Not Specified
Time Spent: Not Specified
Original Estimate: Not Specified
Environment:

Operating System: All
Platform: All


External issue ID: 9042

 Description   

I want to transform OpenFlow Models (Flow, Group, Meter, e.g) to JsonObjects String. I have made NormalizedNode from Flow successfully, but when I use JSONNormalizedNodeStreamWriter as a streamWriter (to write JsonString from Normalized), I got IllegalArgumentExcetion. I want to know if the OF Models are supported to translate to JsonObject already, and would you give correct suggestions to operate?

Following is the exception logs:

java.lang.IllegalArgumentException: List item is not appropriate
at com.google.common.base.Preconditions.checkArgument(Preconditions.java:122)[41:com.google.guava:18.0.0]
at org.opendaylight.yangtools.yang.data.impl.codec.SchemaTracker.startListItem(SchemaTracker.java:144)[57:org.opendaylight.yangtools.yang-data-impl:1.0.4.Boron-SR4]
at org.opendaylight.yangtools.yang.data.codec.gson.JSONNormalizedNodeStreamWriter.startMapEntryNode(JSONNormalizedNodeStreamWriter.java:174)[60:org.opendaylight.yangtools.yang-data-codec-gson:1.0.4.Boron-SR4]
at org.opendaylight.yangtools.yang.data.api.schema.stream.NormalizedNodeWriter$OrderedNormalizedNodeWriter.writeMapEntryNode(NormalizedNodeWriter.java:267)[56:org.opendaylight.yangtools.yang-data-api:1.0.4.Boron-SR4]
at org.opendaylight.yangtools.yang.data.api.schema.stream.NormalizedNodeWriter.wasProcessedAsCompositeNode(NormalizedNodeWriter.java:208)[56:org.opendaylight.yangtools.yang-data-api:1.0.4.Boron-SR4]
at org.opendaylight.yangtools.yang.data.api.schema.stream.NormalizedNodeWriter.write(NormalizedNodeWriter.java:100)[56:org.opendaylight.yangtools.yang-data-api:1.0.4.Boron-SR4]
....



 Comments   
Comment by DongWenying [ 24/Aug/17 ]

My test case is using version Boron-SR4

Comment by Peter Kajsa [ 13/Oct/17 ]

Does this bug still persist ? Can you please retest with newer version of Yangtools, because there is no further Boron SR planned...

Thanks.

Comment by Wenying Dong [ 27/Dec/17 ]

I am sorry that I didn't verify this bug in newer versions, because our team is developing controller based on ODL Boron SR4.

Comment by Robert Varga [ 20/Feb/18 ]

Boron SR4 is desupported, feel free to reopen if it reproduces on Nitrogen/Oxygen (1.2.1+, 2.0.1+).

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