The transaction bump sweeper is the solver's same-nonce replacement loop for stale in-flight attempts. It is useful for unattended operation during fee spikes, but it also automates gas spending. Treat tx_bump.enabled = true as an operational decision, not only a code switch.
- CAS-protected order status and transaction-hash updates for order-stage transitions.
- Same-nonce replacement only for non-terminal attempt lineages that pass the configured age, cap, signer, deadline, and profitability checks.
- Receipt preflight before replacement so a mined lineage tip is reconciled instead of blindly replaced.
- Attempt-ledger writeback during recovery when chain evidence proves a previously broadcast attempt confirmed during downtime.
- Operator-visible events for canonical hash conflicts, attempt-ledger conflicts, receipt preflight failures, missing nonces, missing submission signers, skipped balance checks, and submit failures.
- Deep reorg recovery after a transaction has passed the configured confirmation depth.
- Protection from unsafe fee caps, overly aggressive sweep intervals, or underfunded signer wallets.
- Uniform behavior across RPC providers or mempools. Same-nonce replacement rules are chain/provider dependent.
- Automatic rollback when
TransactionCanonicalHashConflictfires. That event is an alert that an operator must investigate. - Automatic recovery when receipt preflight repeatedly fails and the chain is configured to fail closed.
Before enabling the sweeper on a chain:
- Keep
tx_bump.enabled = falseuntil the chain-specific caps, signer funding, and alerts are configured. - Add only the chains you intend to bump under
tx_bump.chains. - Set
default_max_fee_per_gas_cap_weiand/or per-chainmax_fee_per_gas_cap_wei. - Set
default_max_priority_fee_per_gas_cap_weiand/or per-chainmax_priority_fee_per_gas_cap_wei. - Keep
default_receipt_preflight_fail_closed = trueunless you explicitly accept submitting replacements when the receipt check is unavailable. - Prefer
profitability_gate_fail_closed = truefor chains where strict cost control is more important than liveness. - Choose
pending_threshold_secsabove normal confirmation time for the chain. - Keep
sweep_interval_secshigh enough that one bad condition does not cause noisy repeated attempts. - Set
max_replacements_per_stageto a small number until you have enough bump telemetry to tune it. - Configure low native-balance alerts for every signer used by delivery.
Example:
{
"tx_bump": {
"enabled": false,
"sweep_interval_secs": 15,
"default_pending_threshold_secs": 60,
"default_bump_percent": 15,
"default_max_replacements_per_stage": 3,
"default_max_fee_per_gas_cap_wei": "150000000000",
"default_max_priority_fee_per_gas_cap_wei": "5000000000",
"default_profitability_gate_fail_closed": false,
"default_receipt_preflight_fail_closed": true,
"chains": {
"8453": {
"pending_threshold_secs": 60,
"bump_percent": 15,
"max_replacements_per_stage": 3,
"max_fee_per_gas_cap_wei": "50000000000",
"max_priority_fee_per_gas_cap_wei": "2000000000",
"profitability_gate_fail_closed": true,
"receipt_preflight_fail_closed": true
}
}
}
}Alert on these events before enabling bumping:
| Event | Meaning | Action |
|---|---|---|
TransactionCanonicalHashConflict |
A duplicate confirmation observed a different hash from the stored canonical stage hash. | Investigate chain receipts, reorg risk, and settlement proof inputs before continuing the order manually. |
TransactionAttemptLedgerConflict |
A chain-truth update could not be written to the attempt ledger, usually because another path terminalized the attempt. | Inspect the attempt lineage and confirm the terminal row matches chain truth. |
BumpReceiptPreflightSkipped |
The sweeper could not check whether the tip already mined. | Check RPC health. If fail_closed = true, bumping stops for that attempt until the preflight can run. |
BumpTipAlreadyMined |
Receipt preflight found the lineage tip mined and skipped replacement. | Usually informational. Alert if high volume indicates monitor lag. |
BumpMissingNonce |
The lineage tip has no nonce, so same-nonce replacement is impossible. | Inspect attempt recording and delivery metadata. |
BumpSubmissionSignerUnavailable |
No submission signer is configured for the chain. | Fix delivery/account configuration before enabling the chain. |
BumpBalanceCheckSkipped |
The signer balance check could not be trusted. | Check RPC/balance parsing and signer funding. |
BumpSubmitFailed |
Replacement submission failed outside the known recoverable paths. | Inspect delivery error, nonce state, caps, and RPC health. |
Also alert on:
- CAS retry exhaustion in order state updates.
- Signer native balance below the configured reserve.
- Repeated
BumpCapReached. - Repeated
BumpMaxReplacementsReached.
- Start with
tx_bump.enabled = false. - Configure only the chains that should be bumped under
tx_bump.chains. - Wire alerts for
TransactionCanonicalHashConflict,TransactionAttemptLedgerConflict,BumpReceiptPreflightSkipped, and CAS retry exhaustion. - Confirm signer balances and fee caps during a simulated or natural fee spike.
- Enable one chain at a time.
- Keep initial caps conservative and raise them only with operator approval.
- Review bump events regularly after enabling.
- Do not assume the latest observed hash is safe to settle with.
- Compare stored order hash, attempt ledger rows, and on-chain receipts.
- Check whether a reorg or split-brain monitor path can explain the conflict.
- Continue settlement only after choosing the canonical receipt manually.
- Check RPC health and receipt availability for the affected chain.
- If
fail_closed = true, the sweeper intentionally skips replacement. - If the chain must keep moving, temporarily choose a healthier RPC endpoint before considering fail-open behavior.
- Check whether gas is temporarily spiking or caps are too low for the chain.
- Confirm the order remains profitable before raising caps.
- Prefer per-chain cap changes over raising global defaults.
- Top up the chain-specific signer balance.
- Check whether balance RPCs are failing or returning unparsable values.
- Do not enable additional chains until signer funding alerts are reliable.