Skip to content

Replace prometheus client in the Rails app (monolith) to use the Labkit::Metrics

The Covered Experience framework is being implemented in Labkit (our opinionated library with common utilities across services). In order to use the Covered Experience framework in the Rails apps (the monolith and CustomersDot), first we need to start using the Labkit::Metrics module (that wraps the Prometheus client with our safe defaults), to standardize the way we make use of the metrics client library.

The change proposed here aim at:

  • Update to the newest version of labkit-ruby containing the Labkit::Metrics implementation in Rails
  • Push code to emit metrics using Labkit::Metrics behind a feature flag
  • Enable it in gstg sidekiq+web
  • Enable it in gprd sidekiq
  • Enable it in gprd web
  • Drop old implementation using the Prometheus client directly in favor of Labkit implementation
  • Remove feature flag environment variables
Edited by Hercules Merscher