Repository navigation
fix(proxy-health): skip sweep probes already proven by recent production successes - #14805
Conversation
f1c9687 to
9a4dbfb
Compare
9a4dbfb to
1eb60a0
Compare
|
Thanks — using production traffic to skip redundant probes is a sensible idea and the pure passiveVerdict module is easy to test. Three requests: (1) with recent traffic this changes default sweep behavior, so please put it behind an opt-in flag (or call it out explicitly); (2) |
Maintainer rework: reconciled with release/v3.8.51 — scheduler.ts re-applied on the tip's two-phase sweep (#14805: verdict recorded in decideOneResult from the final, possibly promoted, outcome; dropped on auto-remove); ProxyHealthCell/proxyRegistryConstants keep the tip's transport/upstream fields plus the sweep verdict. Locales: tip keys + only proxyRegistry.sweepVerdict/sweepNoData/sweepLabel.* (nested), no reorder, no __MISSING__. Tests: sweep-verdict + route 13/13, proxy-health scheduler suites 55/55 on tip+head, UI vitest 3/3; typecheck:core clean; i18n ratio/new-keys PASS (check-keys only reports the tip's inherited bs requestTimeline gap); file-size only the inherited opencode.ts tip ceiling. Thank you @maxmad64bis!
|
#14852 Done — all three requests addressed: opt-in flag |
c94b95c to
4745660
Compare
4745660 to
917f669
Compare
|
Re-homed to |
917f669 to
3f6bc9f
Compare
3f6bc9f to
3394632
Compare
3394632 to
851ccc2
Compare
…ion successes Opt-in (PROXY_HEALTH_PASSIVE_SKIP, default off): the proxy health sweep skips the live probe of an endpoint already proven by recent single-provider production successes; a recent attributed failure keeps its probe so auto-disable/auto-remove still apply.
851ccc2 to
96ed7fc
Compare
759ab84
into
cheaper-inference:release/v3.8.52
Summary
Opt-in, default unchanged: with
PROXY_HEALTH_PASSIVE_SKIPunset (defaultfalse) the sweep probes every proxy exactly as before. When enabled, the background sweep stops re-probing an endpoint that recent single-provider production successes already prove alive, so it sends fewer probes. Only an attributed proxy failure keeps the live probe, so confirmed failures still feed auto-disable and auto-remove.Related Issues
Validation
npm run lintTests Added Or Updated
tests/unit/proxy-health-passive-verdict.test.ts: veto on any attributed failure in either order, rewritten from the inverted order.tests/unit/proxy-health-passive-sweep.test.ts(7 cases): healthy skip, kept probe, flag off, multi-provider guard, counted apart.tests/unit/proxy-health-passive-traffic.test.ts(2 mixed cases): real logger → storage → sweep,[fail, ok]and[ok, fail]both keep the probe.Coverage Notes
src/lib/proxyHealth/passiveVerdict.ts:proxy-health-passive-verdict.test.ts, plus the real logger path inproxy-health-passive-traffic.test.ts.src/lib/proxyHealth/scheduler.ts:proxy-health-passive-sweep.test.ts(skip, kept probe, flag off, promotion beside a skip).Reviewer Notes
TARGET_REFUSAL_STATUSESis a frozenReadonlySet([401, 403, 429])read with.has()only: no bound or size test needed. Position on fix(proxies): set aside egress after repeated transport failures with cross-egress success #14802 (gated flag-off): with the flag off the sweep reads nothing extra and probes as before..env.exampleanddocs/reference/ENVIRONMENT.md(append-only additions at distinct anchors) with feat(proxy-subscription): verify the generated core configuration before replacing the file #15142, feat(proxy-subscription): reload the proxy core after a verified config replacement #15238, feat(proxy-subscription): prune nodes the core check rejects, then retry verification #15295 and feat(proxies): accept operator-provided dated egress observations for pool members #15314: merge order with those PRs is anchor-level only, no overlapping lines. With feat(i18n): forward the optional reasoning control in the translation backend #15462 (sharedsrc/lib/proxyHealth/scheduler.ts): either order. With feat(proxy-subscription): warn with a translated count when generation skips entries #15564 (stacked proxy-core config chain on the same base files): either order. Disjoint from fix(dashboard): report headers-wait and client aborts outside transport failures #15248 (this PR: sweep scheduling skip; fix(dashboard): report headers-wait and client aborts outside transport failures #15248: health display counters) — either order; "abandoned" here means an abandoned send excluded from the skip proof, not the headers-wait/client-abort counters of fix(dashboard): report headers-wait and client aborts outside transport failures #15248.