vmware / vmware-openapi-generator

VMware-openapi-generator tool generates open-api documents from vapi metamodel format.
Other
23 stars 19 forks source link

Fixed the validation error caused by $ in the structure's name #29

Closed kunal-pmj closed 5 years ago

kunal-pmj commented 5 years ago

Fixed by replacing '$' with '_'

Signed-off-by: Kunal Singh singhk@vmware.com

vmwclabot commented 5 years ago

@kunal-pmj, you must sign every commit in this pull request acknowledging our Developer Certificate of Origin before your changes are merged. This can be done by adding Signed-off-by: John Doe <john.doe@email.org> to the last line of each Git commit message. The e-mail address used to sign must match the e-mail address of the Git author. Click here to view the Developer Certificate of Origin agreement.

kunal-pmj commented 5 years ago

This fix is to address following issue:

Schema Validation Error

sreeshas commented 5 years ago

Kunal, why do they have $ in the name? Is it because VMODL files contain $ in it? Did you invoke these APIs in APIExplorer or through bindings to make sure they work as expected after your change?

kunal-pmj commented 5 years ago

Hi @sreeshas

No the $ in the structure name do not come from the vmodl definitions. Perhaps they are added by the metamodel service.

I have checked the existing swagger files used in the APIExplorer. They APIs work fine with $ in the name. It is just the external products like Autorest, swagger editor etc report in the Schema validation error.

I have tested the Changes in the local APIExplorer. I will test the modified swagger files with wither of Typescript or Ruby bindings.

Thanks Kunal

sreeshas commented 5 years ago

I have tested the Changes in the local APIExplorer Were you able to make successfull call and get back expected results? If so, this is good.

kunal-pmj commented 5 years ago

Hi @sreeshas

I have addressed the review comments.

Thanks Kunal