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

Classic Incorrect Label Values Problem #88

Open
Smithx10 opened this issue Sep 21, 2018 · 2 comments
Open

Classic Incorrect Label Values Problem #88

Smithx10 opened this issue Sep 21, 2018 · 2 comments

Comments

@Smithx10
Copy link

Smithx10 commented Sep 21, 2018

After a discussion with SuperQ on IRC he concluded the following:

There are labels for "percent", "total", "free", and "used". This makes using Prometheus harder.

If they correctly used the metric, it would look like this:

(mesos_master_allocator_resources_free_cpus + mesos_master_allocator_resources_used_cpus) and mesos_master_elected == 1

At a minimum, they should just delete the percent and total so you could do it this way:

sum without (type) (mesos_master_allocator_resources_cpus) and mesos_master_elected == 1

I guess the request is to follow prometheus exporter best practices.

@SuperQ
Copy link

SuperQ commented Sep 21, 2018

I would probably do these two metrics:

mesos_master_allocator_resources_used_cpus
mesos_master_allocator_resources_total_cpus

This way it's easier to derive things:

  • Used ratio: mesos_master_allocator_resources_used_cpus / mesos_master_allocator_resources_total_cpus
  • Free ratio 1 - (mesos_master_allocator_resources_used_cpus / mesos_master_allocator_resources_total_cpus)
  • Free: mesos_master_allocator_resources_total_cpus - mesos_master_allocator_resources_used_cpus

It also makes it easier to join like pointed out above, and reduces the number of metrics that need to be stored.

@jpeach jpeach changed the title Classic Incorret Label Values Problem Classic Incorrect Label Values Problem Oct 15, 2018
@jpeach
Copy link
Contributor

jpeach commented Oct 15, 2018

This is very similar to #11. I'm in favor of both of these issues, however we need to consider backwards compatibility for everyone who already has dashboards built on the current metrics.

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

No branches or pull requests

3 participants