Closed arthurMll closed 4 years ago
Hi Arthur, Thanks for reporting
Your welcome, are you planning to fix it in the next release? BR,
Hi,
I checked the latest patch and it seems it is almost 100% correct but still there is a miror mistake in the response. Taking the same example used in the original comment: List ítem example https://tools.ietf.org/html/rfc8040#appendix-B.3.9
GET /restconf/data/example:interfaces/interface=eth1 HTTP/1.1 Host: example.com Accept: application/yang-data+json The server might respond as follows:
HTTP/1.1 200 OK Date: Thu, 26 Jan 2017 20:56:30 GMT Server: example-server Content-Type: application/yang-data+json { "example:interface" : [ { "name" : "eth1", "status" : "up" } ] }
Right now the answer of the tool miss the brackets and it would return this:
GET /restconf/data/example:interfaces/interface=eth1 HTTP/1.1 Host: example.com Accept: application/yang-data+json The server might respond as follows:
HTTP/1.1 200 OK Date: Thu, 26 Jan 2017 20:56:30 GMT Server: example-server Content-Type: application/yang-data+json { "example:interface" : { "name" : "eth1", "status" : "up" } }
Could you take a look?
Thanks in advance and great job!
I will try to resolve it - should be an easy fix
fixed in 1.1.14 release
Reviewing the current output of the conversion tool, I have detected an issue with the structure of the body message included in the GET operations expected schemas.
According to RESCONF Specification RFC8040 GET examples point to YANG Container nodes and list nodes, both include the referenced object included in the expected body message, e.g.,:
Container example https://tools.ietf.org/html/rfc8040#appendix-B.3.1
List ítem example https://tools.ietf.org/html/rfc8040#appendix-B.3.9
However the output of the current versión of the tool generates the content of the object itself, without the name of the container/list node, e.g., for the previous examples the output would be:
Container current Swagger spec example https://tools.ietf.org/html/rfc8040#appendix-B.3.1
List ítem current Swagger spec example https://tools.ietf.org/html/rfc8040#appendix-B.3.9