Skip to content

fix(pool): 保留已绑定会话的 VM 调度粘性(v1.4.129) - #1172

Merged
dofastted merged 2 commits into
mainfrom
release/v1.4.129-session-stickiness
Nov 17, 2026
Merged

dofastted merged 2 commits into
mainfrom
release/v1.4.129-session-stickiness

Conversation

@dofastted

@dofastted dofastted commented Nov 17, 2026 •

Copy link
Copy Markdown
Owner

改动

  • Claude 有效绑定优先于调度等级;已排队的续轮不因其他 VM 提权而迁移。保留配额退水、故障回退和等待超时规则。
  • Codex 的可用会话槽优先于等级和权重;新会话及失效后仍按原策略选择。
  • 更新版本和变更日志,沿用原签名载荷。

验证

  • 后端核心 12 文件 264 项通过。
  • 调度、排队、失败回退、会话和计数 8 文件 357 项通过(与核心有重叠)。
  • 改动文件 Biome 格式检查、git diff --check 通过。

Note

Medium Risk
Touches core Claude and Codex VM selection and queue wait logic used on every inference request; misbehavior could mis-route sessions or starve higher-priority VMs, though failovers and quota gates remain in place.

Overview
Bumps to v1.4.129 and documents that active Claude/Codex session bindings now win over schedule_level, weight, and pool rebalancing—follow-up turns and queued continuations stay on the original VM when that VM is still schedulable, instead of hopping to a newly favored account.

Claude (pool-scheduler.mjs): sticky resolution runs before priority filtering in pick, peekAccount, seat opening, and sticky seat waits; changing another VM’s priority no longer promotes a waiter off its pinned home. session_affinity_first is narrowed to post–slot_busy spill follow-through, not whether sticky beats priority (that is now default). Codex (openai-account-selector.mjs, codex-slot-pool.mjs): preferred/bound account is chosen first, without preferredOverridesWeight or a priority/weight gate.

Quota drain, hard unschedulable failover, sticky wait timeouts, and outbound session identity rules are unchanged. Unit tests are updated to lock in the new ordering.

Reviewed by Cursor Bugbot for commit 4fd40e3. Configure here.

@cursor

cursor Bot commented Nov 17, 2026

Copy link
Copy Markdown
Contributor

Bugbot couldn't run - usage limit reached

Bugbot is counted against Cursor usage for this user or team, and this run hit a usage or spend limit.

A user or team admin can review and increase usage limits in the Cursor dashboard.

(requestId: 632d146c-7a26-4c14-9a8a-a79f21518de4)

@dofastted
dofastted merged commit 6b0be52 into main Nov 17, 2026
6 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant