Skip to content

fix(sse): use applied egress key for pool-served proxyless accounts - #14750

Merged
diegosouzapw merged 1 commit into
diegosouzapw:release/v3.8.51from
maxmad64bis:fix/applied-egress-key
Sep 25, 2026
Merged

diegosouzapw merged 1 commit into
diegosouzapw:release/v3.8.51from
maxmad64bis:fix/applied-egress-key

Conversation

@maxmad64bis

@maxmad64bis maxmad64bis commented Sep 24, 2026 •

Copy link
Copy Markdown
Contributor

⚠️ base-red inherited: #14547

Summary

Proxyless accounts served through a shared connection pool retry through the wrong egress path: the rotation keys retries by account fingerprint instead of the egress address the pool actually served, so per-address throttle and set-aside memory never match on retry. The applied egress key (the address the pool served) is now threaded through rotation, throttle and park/resume, so retries hit the same throttle slot and refusal memory as the first attempt. Flag-off behavior is byte-identical.

Related Issues

No linked issue — pool-served proxyless egress keying has no prior ticket.

Validation

  • Change type: sse
  • Focused tests and category gates from the golden path
  • npm run lint
  • Reconciled with the current active release base; focused checks rerun afterward
  • Production-code changes include a new or updated automated test in this PR

Tests Added Or Updated

  • tests/unit/opencode-applied-egress-key.test.ts (new, 10 tests): semaphore isolation per key, set-aside drain with fallback, dedicated-proxy byte-identical keys, park replay legs, cooldown handling; 10/10 green on the rebuilt head.

Coverage Notes

  • New rotation/throttle/park branches covered by the new suite; no coverage movement beyond the new branches.

Reviewer Notes

@maxmad64bis
maxmad64bis force-pushed the fix/applied-egress-key branch from df12102 to f42cb07 Compare September 25, 2026 00:50
@maxmad64bis
maxmad64bis marked this pull request as ready for review September 25, 2026 00:52
@diegosouzapw
diegosouzapw merged commit 0d7e945 into diegosouzapw:release/v3.8.51 Sep 25, 2026
19 of 25 checks passed
diegosouzapw pushed a commit that referenced this pull request Sep 25, 2026
)

Maintainer rework: reconciled with release/v3.8.51 after #14750/#14795/#14810/#14659 — migration 192 now follows 190/191 with no gap, the call_logs INSERT carries has_content/usage_provenance + added_wait_ms/added_wait_cause + the optional resilience_actions column and the #14474 id-collision retry, attempt logging keeps the fresh-UUID row key and reads the added wait late, opencode keeps both the served-account tracker and the park/throttle added-wait counters, the unused getAddedWaitPercentiles was dropped, and file-size-baseline.json was rebuilt from the tip with only this PR's own ceilings (opencode.ts, proxyFetch.ts, core.ts, RequestLoggerDetail.tsx) instead of rewinding unrelated entries. Tests: 133/133 focused (opencode-added-wait, applied-egress-key, egress-throttle, attempt-logging, call-log persistence/id-collision/provenance, resilience-actions); typecheck:core and check:open-sse-typecheck clean; check-file-size and check-migration-numbering OK. opencode-429-park-resume / opencode-429-pool-reselect fail identically on the pure release tip (inherited, not from this PR). Thank you @maxmad64bis!
@maxmad64bis
maxmad64bis deleted the fix/applied-egress-key branch September 30, 2026 00:21
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.

2 participants