Skip to content

Hide active runners in dashboard with 0 jobs running

What does this MR do and why?

Fixes #425768 (closed).

Hide active runners in dashboard with 0 jobs running

This change prevents reported active runners that have 0 jobs running from being shown in the dashboard as active with 0 jobs.

When the backedn sorts by order_most_active_desc runner with no jobs may also get selected so this information should be filtered in the UI.

Screenshots or screen recordings

This is the related UI:

Screenshot_2023-10-10_at_14.59.04

How to set up and validate locally

  1. Make sure you have enabled EE features

  2. In rails console (rails c) enable the feature

    Feature.enable(:runners_dashboard)
  3. Start a job or pipeline

  4. Visit any the Admin -> Runners page http://gdk.test:3000/admin/runners/dashboard

  5. Note the ID of the most active runner. Let's say it's 9598.

    • In rails c run Ci::Build.where(runner_id: 9598).update_all(status: 'canceled')
  6. Refresh the Admin -> Runners page http://gdk.test:3000/admin/runners/dashboard

  7. No runner should have a 0 count

MR acceptance checklist

This checklist encourages us to confirm any changes have been analyzed to reduce risks in quality, performance, reliability, security, and maintainability.

Related to #425768 (closed)

Edited by Miguel Rincon

Merge request reports