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

Fix a bug can cause duplicate metrics and improve the implementation #93

Merged
merged 5 commits into from
Mar 27, 2020

Conversation

tzmtl
Copy link
Contributor

@tzmtl tzmtl commented Mar 26, 2020

In the original implementation when there are more than 10000 objects in a container,
there will be mutiple pages of objects list, the label container_name is the same
one, so it will cause an error of duplicate metrics.

And we don not have to list all objects in a container and count to know how many
objects are in a container. We can get this from container attribute

In the original implementation when there are more than 10000 objects in a container,
there will be mutiple pages of objects list, the label container_name is the same
one, so it will cause an error of duplicate metrics.

And we don not have to list all objects in a container and count to know how many
objects are in a container. We can get this from container attribute
@tzmtl
Copy link
Contributor Author

tzmtl commented Mar 26, 2020

The current implementation still needs improvements. Now it can only get metrics of containers of the account that authenticates with Keystone. It can not list containers of all accounts. No much sense. But I didn't find the method to list containers of all accounts in Go Doc. We will see later how to do implement this.

@niedbalski
Copy link
Member

@tzmtl thank you for your contribution, could you please review the failing tests and add the "bytes" property in the fixtures?

@niedbalski niedbalski merged commit f1b6596 into openstack-exporter:master Mar 27, 2020
niedbalski added a commit that referenced this pull request Mar 27, 2020
Fixes and PR(s) merged.

f1b6596 Fix a bug can cause duplicate metrics and improve the implementation (#93)
a96e106 Add disabled reason label for Nova and Cinder (#91)
bd991bc Add cinder capacity metrics (#89)
f611a68 fix failed tests by adding tenant_id (#94)
c99b822 Added label tenant_id to limits_vcpus_max, limits_vcpus_used, limits_memory_max, limits_memory_used (#92)
767d43f Add log level flag (#90)
9282693 Added check on FIPs associated but not active (#85)
d431ae6 Loadbalancer (#81)
f3c8143 New Neutron metrics + inconsistency checks (#82)
ecad378 Improve testing and add ip_version to availabilities (#77)

Signed-off-by: Jorge Niedbalski <jnr@metaklass.org>
niedbalski added a commit that referenced this pull request Mar 27, 2020
Fixes and PR(s) merged.

f1b6596 Fix a bug can cause duplicate metrics and improve the implementation (#93)
a96e106 Add disabled reason label for Nova and Cinder (#91)
bd991bc Add cinder capacity metrics (#89)
f611a68 fix failed tests by adding tenant_id (#94)
c99b822 Added label tenant_id to limits_vcpus_max, limits_vcpus_used, limits_memory_max, limits_memory_used (#92)
767d43f Add log level flag (#90)
9282693 Added check on FIPs associated but not active (#85)
d431ae6 Loadbalancer (#81)
f3c8143 New Neutron metrics + inconsistency checks (#82)
ecad378 Improve testing and add ip_version to availabilities (#77)

Signed-off-by: Jorge Niedbalski <jnr@metaklass.org>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants