[Supanode](https://supanode.xyz/)[Learn](https://supanode.xyz/learn)Recover Solana stream gaps within a bounded replay window

# Recover Solana stream gaps within a bounded replay window

Persist checkpoints, replay with overlap and switch recovery sources when the gap is too old.

**On this page**[Replay is a recovery mechanism with a boundary](https://supanode.xyz/learn/recover-solana-stream-replay#replay-is-a-recovery-mechanism-with-a-boundary)[A recovery state machine](https://supanode.xyz/learn/recover-solana-stream-replay#a-recovery-state-machine)[Plan the fallback before an outage](https://supanode.xyz/learn/recover-solana-stream-replay#plan-the-fallback-before-an-outage)[Supanode's current scope](https://supanode.xyz/learn/recover-solana-stream-replay#supanode-s-current-scope)[Sources](https://supanode.xyz/learn/recover-solana-stream-replay#sources)

## Replay is a recovery mechanism with a boundary

A stream can expose a starting slot without storing an unlimited archive. Recovery depends on the server's current replay window, the subscription type and its filters. Keep your checkpoint in durable storage and measure the outage in the same units as the replay capability.

## A recovery state machine

```
checkpoint = last_durably_committed_slot()
subscribe(from_slot=checkpoint, filters=desired_filters)
for update in stream:
    persist_idempotently(update)
    advance_checkpoint_after_commit(update.slot)
```

This is Yellowstone-style pseudocode. Resuming at the saved slot creates intentional overlap. Slot alone is not a unique event ID; deduplicate transactions by signature and account updates by their documented update identity.

## Plan the fallback before an outage

1.  Save filters and commitment alongside the checkpoint.
2.  Check whether the checkpoint remains inside the replay window before treating recovery as complete.
3.  If replay is rejected or too old, use a suitable RPC history or indexed dataset for the missing application records.
4.  Join replay and live output through one deduplication path, then verify continuity.

## Supanode's current scope

Supanode provides a 100-slot gRPC replay window and two days of RPC history. These are different products and units. They do not establish a two-day gRPC buffer or a universal SQL retention period. Use the current product Docs for the applicable interface and plan details. If your gap exceeds the available recovery window, retain an explicit incomplete interval rather than claiming that reconnecting restored every event.

## Sources

-   [Yellowstone from\_slot schema](https://github.com/rpcpool/yellowstone-grpc/blob/master/yellowstone-grpc-proto/proto/geyser.proto)
-   [Supanode gRPC documentation](https://supanode.xyz/docs/solana/grpc/overview)
-   [Supanode RPC documentation](https://supanode.xyz/docs/solana/rpc/overview)

## Continue reading

[Solana streaming guide](https://supanode.xyz/blog/solana-data-streaming-guide)[Solana product Docs](https://supanode.xyz/docs/solana/quickstart)[Learn library](https://supanode.xyz/learn)

---
Source: https://supanode.xyz/learn/recover-solana-stream-replay
