You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
Difference between the job being created and starting #202
Hey @cpanato ,
We have multiple runner groups and would like to visualise how long it is taking for a job to be picked up by a runner in a runner group i.e. difference between the job being created and starting. We would like to compare how long on average it is taking for a runner-groups to pick up and begin executing the workflow jobs.
Is this something that could be achieved with the current implementation? I have deployed the exporter but it is not clear to me from the code and the exported metrics if they are relevant to my use case.
I would appreciate your advice and if changes need to be made to the code base, I would be happy to contribute.
Thanks
This is already covered by the exporter since #225: the time between a job being queued and starting is recorded in the workflow_job_duration_seconds histogram with state="queued", labelled by runner_group (plus org, repo, branch, workflow_name and job_name).
Average pickup time per runner group:
sum by (runner_group) (rate(workflow_job_duration_seconds_sum{state="queued"}[5m]))
/
sum by (runner_group) (rate(workflow_job_duration_seconds_count{state="queued"}[5m]))
For percentiles use histogram_quantile(0.95, sum by (le, runner_group) (rate(workflow_job_duration_seconds_bucket{state="queued"}[5m]))).
Closing as answered, feel free to reopen if this does not fit your use case.
Activity
cpanato commentedon Jun 4, 2024
i think we are not capturing the queue part right now (see https://github.com/cpanato/github_actions_exporter/blob/main/internal/server/workflow_metrics_exporter.go#L115 if i am not wrong)
if you want to add that to start capture will be nice
cpanato commentedon Jun 4, 2024
thanks for the issue!
cpanato commentedon Oct 9, 2026
This is already covered by the exporter since #225: the time between a job being queued and starting is recorded in the
workflow_job_duration_secondshistogram withstate="queued", labelled byrunner_group(plusorg,repo,branch,workflow_nameandjob_name).Average pickup time per runner group:
For percentiles use
histogram_quantile(0.95, sum by (le, runner_group) (rate(workflow_job_duration_seconds_bucket{state="queued"}[5m]))).Closing as answered, feel free to reopen if this does not fit your use case.