Implement Rails query layer for CI telemetry
Everyone can contribute. Help move this issue forward while earning points, leveling up and collecting rewards.
Summary
Implement a Rails query layer (GraphQL types and resolvers) to expose CI telemetry traces from ClickHouse, enabling visualization in the GitLab UI.
Requirements
- Add GraphQL types for CI telemetry traces:
CiJobTelemetryTracetype with span fieldsCiJobTelemetrySpantype with timing, attributes, status
- Add GraphQL resolvers:
- Query by
job_id(single job trace) - Query by
project_id+ time range (project-level overview)
- Query by
- Integrate with GLQL for Duo AI queries (Phase 3)
MVC note
This issue is not needed for MVC. For MVC, the DevExp team queries otel_traces directly via Grafana on the Observability CH instance. If DevExp needs Materialized Views for Grafana query performance, they own and manage those MVs on the Observability CH instance themselves.
This issue covers the product-facing query layer (Phase 3, Data consumable by users workstream), which queries the ci_job_telemetry_traces MV on the Production CH instance via ClickHouse::Client.
Architecture Reference
https://handbook.gitlab.com/handbook/engineering/architecture/design-documents/ci_job_telemetry/
Dependencies
ci_job_telemetry_tracesMaterialized View must be created on the Production CH instance first (#590586)- Traces must be flowing (depends on Runner Core work in &20633)
- Production CH exporter pipeline must be configured in the OTEL Collector (Observability team)