Add SLI for Rails to OpenBao calls

Why this MR ?

  • Every Secrets Manager secret read, write and permission check crosses one HTTP hop from Rails to OpenBao
  • We already have three Prometheus metrics on that hop, but they are plain counters and a histogram, so nothing can alert on them and they never reach our stage group error budget
  • The documented way to get both is an application SLI - https://docs.gitlab.com/development/application_slis/
  • Covers part of #611251

What does this MR do ?

  • Adds the openbao_client_calls application SLI and records it from the same place the existing metrics are recorded
  • Error rate only, no apdex - this hop's latency is dominated by OpenBao's four synchronous audit POSTs back into Rails, so any target worth setting would be red from day one
  • The existing duration histogram still carries the percentiles
  • Documents the two new counters

Notes for review

  • The SLI module sits in lib/ rather than ee/lib/ because Gitlab::Instrumentation::Openbao is already a FOSS file and is the call site, and a FOSS file cannot reference an EE constant

References

Edited by Jayakrishnan Mallissery

Merge request reports

Loading
Loading