Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

api: listApis command missing 'tags' field for many responses #3002

Closed
csquire opened this issue Nov 5, 2018 · 0 comments
Closed

api: listApis command missing 'tags' field for many responses #3002

csquire opened this issue Nov 5, 2018 · 0 comments

Comments

@csquire
Copy link
Contributor

csquire commented Nov 5, 2018

ISSUE TYPE
  • Bug Report
COMPONENT NAME
API
CLOUDSTACK VERSION
4.9.3.0, 4.11.2.0
CONFIGURATION

N/A

OS / ENVIRONMENT

N/A

SUMMARY

At some point around 4.9, many API command stopped reporting the tags field in their API response fields. For example UserVMResponse and TemplateResponse. I believe this was caused by this commit. After this change ApiDiscoveryService is not getting the tags field from the superclass of the response classes.

The xanzy go-cloudstack client depends on the output of listApis to generate it's Cloudstack client SDK. In later versions of the xanzy cloudstack client, the tags fields are missing from many of the responses. This in turn means that the Terraform Cloudstack Provider (which uses the xanzy client) cannot use a newer version of xanzy go-cloudstack without a breaking change.

I also believe the current version of xanzy go-cloudstack used by the Terraform Cloudstack Provider may be incompatible with Cloudstack 4.11 because of a type change in the Cloudstack API, changing ProjectResponse.secondaryStorageTotal from an int to a float. Following semver, breaking changes like this type change shouldn't be made in minor version updates, but that's a different conversation.

STEPS TO REPRODUCE
Open the following and notice that the listVirtualMachines API does not advertise the `tags` field in the response: 
http://localhost:8080/client/api?command=listApis&response=json&name=listVirtualMachines
EXPECTED RESULTS
The `tags` field should be present.
ACTUAL RESULTS

The tags field is not present.


Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

3 participants