Skip to content

test(combo): guard same-provider cascade is handled by connection cooldown (#3200) - #3194

Merged
diegosouzapw merged 1 commit into
release/v3.8.11from
test/combo-resilience-eval
Jun 5, 2026
Merged

diegosouzapw merged 1 commit into
release/v3.8.11from
test/combo-resilience-eval

Conversation

@diegosouzapw

Copy link
Copy Markdown
Owner

What

Test-only regression guard born from a TDD evaluation of the two combo-resilience PRs (#3145, #3169) against issue #3200 ("combos stay stuck on same-provider targets, never falling back").

Finding

The cascade #3200 describes is already prevented by the existing connection-cooldown. A real chat-pipeline test (seed openai + claude, a combo with 3 openai targets + 1 claude target, openai returning 404/5xx) shows:

  • After the first openai failure, markAccountUnavailable cools the connection down.
  • The remaining same-provider targets (openai/o1-mini, openai/gpt-4.1-mini) are pre-screened out before any dispatch ("no credentials available").
  • The provider is hit exactly once, then the combo falls back to claude.

openaiCalls === 1 on the clean baseline — i.e. before either PR. This is stronger than PR #3145's provider-level counter (which would dispatch twice before short-circuiting) and needs neither PR #3169's parallel cooldown cache nor its rewrite of combo-provider-cooldown.test.ts.

Change

Adds tests/unit/combo-same-provider-cascade.test.ts locking in this behavior so a future change can't silently regress the cascade guard. No production code changed.

Validated: passes on release/v3.8.11 baseline; the existing combo suite (combo-provider-cooldown, combo-routing-engine, combo-config — 97 tests) stays green.

…tion cooldown (#3200)

Regression guard born from the TDD evaluation of PRs #3145/#3169. Proves that
when a combo has multiple targets from the same provider and that provider fails
(404 or 5xx), the existing connection-cooldown marks the connection unavailable
after the FIRST failure, so the remaining same-provider targets are pre-screened
out before dispatch — the provider is hit exactly once, then the combo falls back
to a different provider.

This locks in the current behavior so a future change can't silently regress the
cascade guard. No production code changed (test-only).
@gemini-code-assist

Copy link
Copy Markdown
Contributor

Warning

You have reached your daily quota limit. Please wait up to 24 hours and I will start processing your requests again!

@diegosouzapw
diegosouzapw merged commit d3422c1 into release/v3.8.11 Jun 5, 2026
2 checks passed
@diegosouzapw
diegosouzapw deleted the test/combo-resilience-eval branch June 5, 2026 12:53
HouMinXi pushed a commit to HouMinXi/OmniRoute that referenced this pull request Aug 2, 2026
Poid-ZA pushed a commit to Poid-ZA/OmniRoute that referenced this pull request Aug 5, 2026
muhamadgalihsaputra pushed a commit to niyatna/NiyatnaRoute that referenced this pull request Sep 27, 2026
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