发布

  • feat(supervisor): add node affinity rules for large machine worker pool scheduling (#2869)

    frostbyte_neo 发布于 2026-01-13 09:54:47 +00:00 | 1247 次提交 在此版本后已推送到 main

    Background
    Runs with large-1x or large-2x machine presets are disproportionally
    affected by scheduling delays during peak times. This is in part caused
    by the fact that the worker pool is shared for all runs, meaning large
    runs compete with smaller runs for available capacity. Because large
    runs require significantly more CPU and memory, they are harder for the
    scheduler to bin-pack onto existing nodes, often requiring a node with a
    significant amount of free resources or waiting for a new node to spin
    up entirely. This effect is amplified during peak times when nodes are
    already densely packed with smaller workloads, leaving insufficient
    contiguous resources for large runs. Also, large runs make up a small
    percentage of the total runs.

    Changes

    This PR adds Kubernetes node affinity settings to separate large and
    standard machine workloads across node pools.

    • Controlled via KUBERNETES_LARGE_MACHINE_POOL_LABEL env var (disabled
      when not set)
    • Large machine presets (large-*) get a soft preference to schedule on
      the large pool, with fallback to standard nodes
    • Non-large machines are excluded from the large pool via required
      anti-affinity
    • This ensures the large machine pool is reserved for large workloads
      while allowing large workloads to spill over to standard nodes if needed
    下载附件