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

[LIB] improve struct parameters name generated by codegen #1023

Open
madfelps opened this issue Apr 26, 2024 · 1 comment
Open

[LIB] improve struct parameters name generated by codegen #1023

madfelps opened this issue Apr 26, 2024 · 1 comment
Labels
enhancement New feature or request k8s New feature or request by mgc-k8s team lib lib related improvements wontfix This will not be worked on

Comments

@madfelps
Copy link
Contributor

madfelps commented Apr 26, 2024

In VM creation, for instance, we use this command:

image

Inside virtualMachine.CreateParameters, the Image field has two fields (CreateParameterImage0 and CreateParametersImage1) where each of them has only one property (Id and Name, respectively).

It would be better if the Image property have the fields Id and Name directly, instead of CreateParametersImage0 and CreateParametersImage1. The same with others fields as MachineType and Network.

@madfelps madfelps added enhancement New feature or request lib lib related improvements k8s New feature or request by mgc-k8s team labels Apr 26, 2024
@madfelps
Copy link
Contributor Author

madfelps commented May 2, 2024

Also, I believe some return values could have a better name as well. For instance, the List method from virtual_machine returns a ListResult struct, which has ListResultInstances struct parameter, which has ListResultInstancesItem struct parameter (check image below)

image
image
image
image

Maybe ListResultInstancesItem could be just vm/machine/instance and the others names may follow a more direct and clean name

@publi0 publi0 added the wontfix This will not be worked on label Oct 16, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request k8s New feature or request by mgc-k8s team lib lib related improvements wontfix This will not be worked on
Projects
None yet
Development

No branches or pull requests

2 participants