Skip to content

Select pending builds from `ci_pending_builds` table

Description

This is the next iteration after #329764 (closed).

This iteration is about using the recently introduced table to accelerate queuing. The outcome of the previous iteration was to validate that the new table can receive inserts and deletes in a transaction with status change in ci_builds in a way that this does not make performance noticeably worse.

In this iteration we want to actually use this table.

Proposal

  1. Update the ci_pending_builds_maintain feature flat to default enabled,
  2. Backfill ci_pending_builds table during a post deployment migration,
  3. Select builds from ci_pending, join with ci_builds and other tables,
  4. Enable this mechanism on production using feature flag toggle.
Edited by Grzegorz Bizon