⚠ INTERNAL — Operator UX mock · Design preview of V2 development path · demo-wired ≠ production-live · back to dev guide
Polygon · pUSD 10
📓 Developer Guide 📋 Reason Codes 📈 Shadow Mode
JD John Doe · Admin

RPCFailoverManager

sec.rpcfailovermanager
Security planned Spec started frozen

Probe RPC providers continuously and fail over before a stale endpoint poisons our chain view.

What it does

Probe RPC providers continuously and fail over before a stale endpoint poisons our chain view.

Pipeline placement

runs after: System startup; continuous background probe RPCFailoverManager runs before: Any bot that makes on-chain read calls

Applies to: All Polygon RPC endpoints in the configured provider pool

Why it matters

If this failsConsequence
Single RPC endpoint goes staleAll bots reading chain state see an outdated block, causing mispriced or incorrectly-scoped orders.
No quorum check across providersA forked or malicious RPC can poison chain state views used for contract address and balance checks.
No auto-quarantine of degraded providerA slow or error-prone endpoint keeps being polled, adding latency to every on-chain check.

Inputs

Polymarket inputs

InputSourceRequiredUse
eth_blockNumber from each configured RPC provideronchainrequiredMeasure block height divergence across providers to detect stale endpoints.

Internal inputs

InputSourceRequiredUse
Configured RPC provider pool and probe_interval_sAdmin UIrequiredPool of providers to probe and failover thresholds.
KillSwitch active flagKillSwitchrequiredHalt all chain reads during global pause.

Authority

What this bot is permitted to do

Reject Pause

State

Readiness

Spec started

Status

planned

Class

Guardrail

Default mode

shadow_only

Developer owner

Polytraders core

Capital impact

Direct

Reason codes emitted

CodeSeverityMeaningAction
KILL_SWITCH_ACTIVEHARD_REJECTGlobal kill switch is active.Immediately return DENY.
RPC_QUORUM_LOSTHARD_REJECTFewer than min_providers_quorum healthy RPC providers available.Return DENY on all chain reads until quorum restored.
RPC_PROVIDER_LAGGINGWARNA provider's block height lags by 2 blocks; approaching quarantine threshold.Log warn; keep provider active; increase probe frequency.
RPC_QUORUM_WARNWARNOnly min_providers_quorum providers remain healthy; one more failure triggers reject.Emit warn; notify ops.
RPC_FAILOVER_INFOINFOPrimary provider switched to a new endpoint.Log info; no action needed.

Used by

Reverse index — strategies that currently reference sec.rpcfailovermanager. If you change this bot's authority or reason codes, these strategies must re-pass shadow.

StrategyStateActivity
NBA H2H — moneyline market-makedemo-wiredlast triggered 33m ago
US Elections — sentiment fadedemo-wiredlast triggered 40m ago

Showing 2 of 2 · demo-wired ≠ production-live

Why this matters

Security bots does NOT propose or execute trades; only guards signing and wallet operations. Understanding the authority boundary prevents misuse and makes promotion-gate reviews faster and more reliable. View raw spec JSON →
Polytraders Operator UX Mock · INTERNAL · demo-wired ≠ production-live · the plan · reason codes · shadow-mode pipeline
⚙ Page Configuration
Current page settings
Loading configuration…