Skip to content

Conversation

@britaniar
Copy link
Collaborator

@britaniar britaniar commented Feb 12, 2026

Description of your changes

Fixes #

I have:

  • Added two stage level histogram metrics:

    1. One to see how long a user takes to approve the before/after stage approval requests
    2. How long it takes a stage to complete excluding all stage tasks.
  • Added an integration case for testing only before stage task (missed previously and added to test the new metric)

  • Updated integrations tests to validate new emitted metrics.

  • Run make reviewable to ensure this PR is ready for review.

How has this code been tested

  • Integration Test

Special notes for your reviewer

What the metrics look like:

fleet_workload_update_run_stage_cluster_updating_duration_seconds_bucket{namespace="prod",name="run-42",le="10"} 1
fleet_workload_update_run_stage_cluster_updating_duration_seconds_bucket{...,le="30"} 4
fleet_workload_update_run_stage_cluster_updating_duration_seconds_bucket{...,le="60"} 7
...
fleet_workload_update_run_stage_cluster_updating_duration_seconds_bucket{...,le="+Inf"} 9

fleet_workload_update_run_stage_cluster_updating_duration_seconds_sum{...} 1450
fleet_workload_update_run_stage_cluster_updating_duration_seconds_count{...} 9
fleet_workload_update_run_approval_request_latency_seconds_bucket{namespace="prod",name="run-42",stageTask="approve",le="60"} 3
fleet_workload_update_run_approval_request_latency_seconds_bucket{...,le="300"} 8
fleet_workload_update_run_approval_request_latency_seconds_bucket{...,le="900"} 12
...
fleet_workload_update_run_approval_request_latency_seconds_bucket{...,le="+Inf"} 15

fleet_workload_update_run_approval_request_latency_seconds_sum{...} 12450
fleet_workload_update_run_approval_request_latency_seconds_count{...} 15

britaniar and others added 3 commits February 12, 2026 11:59
@codecov
Copy link

codecov bot commented Feb 12, 2026

Codecov Report

❌ Patch coverage is 91.83673% with 4 lines in your changes missing coverage. Please review.

Files with missing lines Patch % Lines
pkg/controllers/updaterun/metrics.go 90.24% 2 Missing and 2 partials ⚠️

📢 Thoughts on this report? Let us know!

@britaniar britaniar marked this pull request as ready for review February 12, 2026 22:23
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant