Skip to content

ADR 007: Implement CI/CD Metrics Collector

  • Status: Superseded
  • Date: 2026-02-19
  • Author: Victoria Cheng
  • Superseded: 2026-02-24. Raw CI metrics lacked a data consumer, and GitHub Actions natively surfaces the same signals (duration, status, runner). Future observability efforts will focus on cost and energy correlation rather than raw metric collection.

Context and Problem Statement

Understanding the performance and reliability of CI/CD pipelines is crucial for optimizing developer velocity and platform health. Without clear metrics on build duration, success rates, and resource consumption, identifying bottlenecks, justifying platform improvements, and ensuring a consistent developer experience becomes challenging. Ad-hoc observation is insufficient for data-driven decision-making.

Decision Outcome

Implement a metrics-collector as a reusable GitHub Action designed to gather key performance indicators (KPIs) from CI/CD workflow runs. This action will capture metrics such as job duration, status (success/failure), runner type, and potentially resource utilization (if self-hosted runners provide this data). The collected data will be formatted (e.g., JSON) and made available as an artifact or pushed to a central repository for analysis.

Consequences

Positive

  • Data-Driven Optimization: Enables identification of slow or flaky jobs, leading to targeted performance improvements.
  • Enhanced Observability: Provides clear visibility into the health and efficiency of CI/CD pipelines.
  • Improved Developer Experience: Faster and more reliable CI/CD directly impacts developer productivity.
  • Justification for Resources: Provides data to support investments in platform infrastructure and tooling.

Negative

  • Integration Overhead: Requires integration into existing CI/CD workflows to collect data.
  • Data Storage/Analysis: Needs a mechanism for storing and visualizing the collected metrics.
  • Privacy Concerns: Careful consideration for what data is collected and how it's stored.

Verification

  • [x] Metric Capture: The action successfully captures job duration, status, and runner OS.
  • [x] Output Format: Metrics are output in a standardized, parseable format (e.g., JSON).
  • [x] Integration: The action can be successfully integrated into a sample workflow to collect data.