Join GitHub today
GitHub is home to over 28 million developers working together to host and review code, manage projects, and build software together.Sign up
Add extra prometheus metrics #32792
Signed-off-by: Roberto Gandolfo Hashioka email@example.com
- What I did
- How I did it
Extended the existing
- How to verify it
- Description for the changelog
@aluzzardi I agree that those metrics should be in swarmkit, but they are not there yet! So nothing prevents us to expose the swarm info data at scrape time using the approach @aaronlehmann suggested (prometheus Collector). I'll remove the swarm related metrics from this PR as @alfred-landrum offered his help to implement the prometheus Collector to expose the engine/swarm info (https://godoc.org/github.com/prometheus/client_golang/prometheus#ex-Collector) -- he has already worked on that in the past.
@rogaha The thing is, the names, namespace and labels will be different in swarmkit which will break whoever is scraping those.
Are we okay with this? If so, then it's fine.
Otherwise, I've put together a proof of concept here (it's not much more complicated than what has been done here):
@stevvooe here are the output examples:
total number of successful triggered builds
total number of triggered builds
total number of failed triggered builds
Having a high or practically unbounded number of label values on a metric is unwise. I'd suggest squashing the errors down to a few general classes (e.g. syntax error) and if the user wants more detail they can look at logs.
The unit-tests failures don't seem to be related to the changes in this
May 9, 2017
PowerPC failure is a flaky test;
Let me trigger once