Feat/soroban reconciliation gap backfill#1012
Merged
Olowodarey merged 7 commits intoJun 22, 2026
Merged
Conversation
Per-contract sync checkpoint to track last indexed ledger, chain head, and reconciliation metadata for gap detection and self-healing indexing. Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
Periodic reconciliation job that detects gaps between the last indexed ledger and chain head, then backfills missing events as PENDING for the existing indexer retry pipeline to process. Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
Both IndexerService.pollContractEvents and SorobanListener.pollEvents now call ReconciliationService.advanceCheckpoint after persisting events so the checkpoint never advances past events that failed to persist. Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
GET /api/indexer/health/reconciliation exposes reconciliation status, whether it is running, last backfill count, and the lag in ledgers (always >= 0) between chain head and last indexed ledger. Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
…erModule Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
…env vars Optional configuration for the reconciliation job with sensible defaults. Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
|
The latest updates on your projects. Learn more about Vercel for GitHub.
|
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Soroban on-chain event reconciliation & gap-backfill job
Adds a self-healing reconciliation layer to the indexer that detects and backfills gaps between the last indexed ledger and chain head when the process goes down, RPC drops, or events are missed.
Changes
@Cronjob that detects ledger gaps and backfills missing events as PENDING for the existing retry pipelineIndexerServiceandSorobanListeneradvance the checkpoint; checkpoint never advances past events that failed to persistGET /api/indexer/health/reconciliationreports reconciliation status and non-negative lagRECONCILE_ENABLED,RECONCILE_INTERVAL_MS,RECONCILE_WINDOWwith sensible defaultschain_sync_checkpointstableTest plan
Closes #1004