You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
feat(processor): add batch block fetching for improved throughput (#69)
Implement batch block fetching to request multiple blocks at once using
BatchCallContext RPC, with proper backpressure handling and contiguous-only
batching.
Changes:
- Add BlocksByNumbers to Node/DataSource interfaces for batch RPC
- Implement batch RPC using go-ethereum's BatchCallContext
- Add GetAvailableCapacity and ValidateBatchWithinLeash to Limiter
- Add NextBlocks method to State Manager for batch number generation
- Add InitBlocks batch method to PendingTracker using Redis pipeline
- Refactor ProcessNextBlock in all processors to support batch fetching
- Add exponential backoff with jitter for backpressure handling
The batch size is limited by min(maxPendingBlockRange, availableCapacity)
and stops at the first missing/not-found block to maintain contiguity.
0 commit comments