Skip to content

Fix seeded job queue durations

What does this MR do and why?

Describe in detail what your merge request does and why.

This MR fixes the calculations used by the gitlab:seed:runner_fleet rake job to seed CI builds on a new runner fleet. Namely, it:

  • Changes to use seconds instead of minutes for more granularity in generated random durations;
  • Fixes a bug in conversion between minutes and seconds in PIPELINE_START_RANGE_MAX_IN_MINUTES resulting in unrealistically high queue times

Screenshots or screen recordings

Screenshots are required for UI changes, and strongly recommended for all other merge requests.

header
image
image

How to set up and validate locally

Numbered steps to set up and validate the change are strongly suggested.

  1. Check logs in one terminal window: tail -n200 log/application.log
  2. Run bundle exec rake 'gitlab:seed:runner_fleet[root, rf-]'
  3. Open http://gdk.test:3000/admin/jobs. There should be new jobs there, and their queued duration should be inferior to 5 minutes.
  4. Open http://gdk.test:3000/admin/runners. In the section pointed in the screenshots above, you should see a duration inferior to 300 s.

MR acceptance checklist

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

Edited by Pedro Pombeiro

Merge request reports

Loading