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

Use gophercloud instead of goose #26

Closed
alistarle opened this issue Sep 20, 2019 · 7 comments
Closed

Use gophercloud instead of goose #26

alistarle opened this issue Sep 20, 2019 · 7 comments
Labels
enhancement New feature or request
Milestone

Comments

@alistarle
Copy link
Contributor

The go Openstack SDK used for many project like terraform or packer is gophercloud, it count more than 3k commits, and is actively used by the community with 600+ issue and 350+ stars.

Indeed, more or less all the openstack actions are present in gophercloud, whereas goose lacks a lot of thing (by example aggregate host in order to return it on many hypervisors metrics). It also provide built in reading of clouds.yaml by example

clientconfig.GetCloudFromYAML(clientOpts)

So it really simplify the code of the exporter

I suggest to migrate to gophercloud in order to be able to add new feature more easily and to use more supported backend library.

@alistarle
Copy link
Contributor Author

BTW I begin to work on that and already migrate half of the metrics to gophercloud, I will make a draft PR when all will be migrated.

@niedbalski
Copy link
Member

@alistarle I am ok with your proposal, If you could draft a PR that we can follow up, it would be really helpful.

@niedbalski niedbalski added the enhancement New feature or request label Sep 21, 2019
@niedbalski niedbalski added this to the 0.3.0 milestone Sep 21, 2019
@alistarle
Copy link
Contributor Author

Thanks, here is the draft, it works but there is still a lot of work to do : #27

@niedbalski
Copy link
Member

@alistarle Thank you much. Could you please review the comment on #27? Please rebase on top of the gophercloud branch and re-submit, lets work from there rather than master.

Thanks again for your work on this!

@niedbalski
Copy link
Member

niedbalski commented Sep 30, 2019

@alistarle

I've merged this PR and the master builds are using GopherCloud. Please let me know if this
works for you so I can do a initial release using the new gophercloud based code.

I've also added yourself to the list of contributors[1] for your great contribution implementing
this feature.

Feel free to send me PR(s) if I missed any detail or if you have any new metrics that
you think might be useful.

[0] #30
[1] https://github.com/openstack-exporter/openstack-exporter/blob/master/CONTRIBUTORS.md

niedbalski added a commit that referenced this issue Sep 30, 2019
This is a continuation pr of #27 for fixing #26

[ X] Use the --os-client-config args (currently, loading of the clouds.yml are done trough this function)
[ X] Check that all the client really use the params from the clouds.yml (endpoint type, tls, etc...)
[ X] Fix the tenant_id of the volume_status metrics (extended attribute of the volume API)
[X ] Check that the refresh_client really works (make tests)
[ X] Write/Fix the unit tests
@niedbalski
Copy link
Member

I am closing this bug as no other feedback has been provided. Feel free to open a new issue if you find any bug or missing implementation.

Thanks!

@alistarle
Copy link
Contributor Author

Sorry I was not available these days, but thanks for merging this code ! I will test this week then add some metrics I was looking for for moving to gophercloud

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

2 participants