Closed germanbecker closed 7 years ago
Or rather, use the COUNTER metic_type
Hi germanbecker,
Please note that the CPU collector (and most other collectors) have advanced far beyond what you see here in the BrightcoveOS / Diamond project. This project has ceased, and been relocated to https://github.com/python-diamond/Diamond There's a chance the feature you're looking for may have already been implemented over there. Unfortunately I think google search results still favor the BrightcoveOS repo over the python-diamond repo so a lot of folks find this project first and then we have to redirect them over to the other one.
Hope to see you on the other side.
Hi,
I was checking the code of the CPU collector and see that it works by waiting a hardcoded interval (1 second) and reporting the difference. By working this way, the value represents the CPU usage under that particular second. I think this collector (and any collector that works with counters) should rather store the counters of a previous run (i.e. in a temporary file) and then substract them to current counters. This way no cpu tick would be "lost" I would be happy to contribute a solution but i know nothing about github