Add slow operation logger for CI config permission checks
What does this MR do and why?
This change adds a reusable SlowOperationLogger module to instrument
slow operations during CI pipeline configuration. Initially
used to log slow download_code permission checks, which helps
diagnose intermittent slowness.
The logger captures DB, Gitaly, and Redis counters when operations
exceed a configurable threshold (default 5 seconds, configurable
via CI_SLOW_OPERATION_THRESHOLD_SECONDS env var).
References
Related to #590016
MR acceptance checklist
Evaluate this MR against the MR acceptance checklist. It helps you analyze changes to reduce risks in quality, performance, reliability, security, and maintainability.