Add Prometheus metrics endpoint and basic infrastructure to meter code
Adds Prometheus Client gem along with basic configuration allowing turning on metrics and instrumentation.
Exposes prometheus metrics acquired by them gem along with other health metrics gathered by other means.
Are there points in the code the reviewer needs to double check?
For turning on prometheus metrics, I used ApplicationSettings model however, Prometheus gem also requires its user to specify folder where shared files containing metrics will be kept.
To control that folder location I kept using ENV['prometheus_multiproc_dir'] as the library only way to configure the folder is through the env variable
Why was this MR needed?
More metrics
Screenshots (if relevant)
Does this MR meet the acceptance criteria?
-
Changelog entry added, if necessary -
API support added - Tests
-
Added for this feature/bug -
All builds are passing
-
-
Conform by the merge request performance guides -
Conform by the style guides -
Branch has no merge conflicts with master
(if it does - rebase it please) -
Squashed related commits together
What are the relevant issue numbers?
Related to: #29118 (closed)
Edited by Paweł Chojnacki