Skip to content

chore(ci): fold node-slot scheduling into the priority scheduler - #5073

Merged
adibarra merged 1 commit into
mainfrom
chore/fold-node-slot-scheduler
Nov 13, 2026
Merged

adibarra merged 1 commit into
mainfrom
chore/fold-node-slot-scheduler

Conversation

@adibarra

Copy link
Copy Markdown
Collaborator

Summary

Node-slot admission (the nodes:N runner label and ci-lease-* leases) was gated behind a separate NODE_SLOT_SCHEDULER_ENABLED repo variable on top of PRIORITY_SCHEDULER_ENABLED. The priority controller already supports nodes:N and ci-lease-*, and every priority-scheduled job must carry nodes:N to be eligible, so the second flag no longer has a valid "off" state.

This change makes PRIORITY_SCHEDULER_ENABLED the only switch.

  • When it is true, every self-hosted job requests nodes:N together with its ci-job-* and ci-attempt-* labels.
  • When it is not true, jobs target the plain runner label, as before.

operatorx-sweep.yml already worked this way and is unchanged.

Changes

  • benchmark-tmpl.yml, benchmark-multinode-tmpl.yml, profile.yml, speedbench-al.yml: remove the NODE_SLOT_SCHEDULER_ENABLED branch and the label list that omitted nodes:N.
  • collectivex-sweep.yml: always include nodes:{matrix.nodes} when the priority scheduler is enabled.
  • RUNNER_SETUP.md: describe node leasing as part of the priority scheduler and drop the separate flag.

Rollout

After merge, delete the now-unused repo variable with gh variable delete NODE_SLOT_SCHEDULER_ENABLED. Deleting it before merge would make the old workflows on main drop nodes:N from queued jobs.

Testing

  • No NODE_SLOT references remain in the repo.
  • actionlint reports no issues in the changed runs-on expressions.

@claude claude Bot left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Nothing blocking. The comments below are optional suggestions. There is no need to push a fix for them before merging.

Beyond the inline finding, I also checked the rewritten runs-on expressions. The collectivex ',{0},{1},{2}' rewrite and the multinode inputs.node-count path each produce a valid JSON array with exactly one nodes:N entry when the priority scheduler is on. When it is off, both fall back to the plain runner label.

Extended reasoning...

The change touches the self-hosted runs-on label expressions in five GPU workflows and the runner setup doc. It touches no auth, injection or data-exposure surface. One finding was reported inline. This note only records the expression checks that came out clean.

Comment on lines +207 to +208
If `PRIORITY_SCHEDULER_ENABLED` is disabled, workflows omit `nodes:N`, `ci-job-*`,
and `ci-attempt-*` and target the plain runner label. The priority score also

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🟡 (optional) Once operators delete NODE_SLOT_SCHEDULER_ENABLED as the rollout says, reruns of pre-merge runs and dispatches from unrebased branches queue without nodes:N and never start. Those runs read the old templates, which add nodes:N only when that variable is 'true'. Their fallback array is ["self-hosted",runner,ci-job-*,ci-attempt-*]. AGENTS.md:86 says a job without nodes:N can never be admitted. Fix: keep the variable set to 'true' until no run can still read an old template, and say so in RUNNER_SETUP.md. That means outliving the 30-day rerun window and every branch that still has the gated runs-on.

Why this was flagged

The PR description's rollout says to run gh variable delete NODE_SLOT_SCHEDULER_ENABLED after merge. A rerun of a run started before the merge uses that run's original workflow commit but reads vars when it reruns. In the base benchmark-tmpl.yml and benchmark-multinode-tmpl.yml, and in profile.yml, speedbench-al.yml and collectivex-sweep.yml, the vars.NODE_SLOT_SCHEDULER_ENABLED == 'true' branch is false once the variable is deleted. The || fallback then emits a label list without nodes:N. Manual workflow_dispatch of e2e-tests.yml, profile.yml or speedbench-al.yml from a feature branch cut before this merge hits the same path. AGENTS.md:86 says such a job is ineligible for priority scheduling and labels cannot be added later, so it stays queued until it times out. On the base branch, with the variable left at 'true', these jobs carry nodes:N and get admitted. Nothing in the repo warns operators to wait before deleting the variable.

Verification: Trigger: an operator deletes NODE_SLOT_SCHEDULER_ENABLED as the PR's Rollout section says. AGENTS.md:86 (base, unchanged) says: "A queued job without the label is ineligible for priority scheduling, and labels cannot be added later". The diff also drops the variable from RUNNER_SETUP.md:207-208, so no doc tells operators to keep it until old runs age out.

@adibarra
adibarra merged commit 00ba388 into main Nov 13, 2026
15 checks passed
@adibarra
adibarra deleted the chore/fold-node-slot-scheduler branch November 13, 2026 23:27
zyongye added a commit that referenced this pull request Nov 15, 2026
Picks up the priority-scheduler change (#5073) so sweep jobs carry the nodes:N runner label. Conflict in perf-changelog.yaml resolved by keeping main's entries and this PR's entry last.

Co-Authored-By: Claude Fable 5.2 <noreply@anthropic.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

Status: Done

Development

Successfully merging this pull request may close these issues.

1 participant