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
{{ message }}
Repository navigation
[BUG] Indexer drops events when the Redis stream's MAXLEN trims unread entries #891
The Redis stream used to buffer raw Soroban events is capped with MAXLEN ~ N, and under a burst of on-chain activity, entries are trimmed before the indexer consumer group has read them.
Component
Backend
Frontend
Smart Contract
SDK
Documentation
Other:
Steps to Reproduce
Configure a small MAXLEN for testing.
Produce events faster than the indexer consumes them (simulate a burst).
Check the consumer group's lag versus the stream's actual length.
Confirm some events were trimmed before being read.
Expected Behavior
The stream should be sized (or use a consumer-aware trimming strategy) so unread entries are never trimmed, or there should be a fallback re-sync from the RPC.
Actual Behavior
Under burst load, unread events are trimmed and permanently lost from the indexer's perspective.
Environment
Node Version: 20.x
OS: Linux / macOS
Browser (if applicable): N/A
Network (Testnet/Mainnet): Testnet
Error Messages/Logs
N/A — no error output; behavior is incorrect but silent.
Screenshots
N/A — backend/API issue, not applicable.
Additional Context
MAXLEN ~ approximate trimming doesn't account for consumer group read position.
Possible Solution
Switch to XTRIM MINID based on the slowest consumer group's last-delivered ID, or add a periodic reconciliation pass against the RPC as a safety net.
I'd like to help resolve this issue. Redis operations or stream consumer pipelines need robust handling around timeouts, atomic ttl expiration, and consumer group pel retention. I plan to audit the redis transaction or pipeline operations to guarantee atomic key creation and ttl assignment and ensure consumer group acknowledgment and stream retention parameters prevent unexpected data loss, followed by propagate configured timeout deadlines cleanly across pipelined commands.
I'll simulate high-throughput or network delay scenarios to verify bounded memory and zero dropped entries to verify everything passes cleanly.
Happy to take this on if you can assign it over. Will get a clean PR ready promptly.
I reviewed the requirements for Indexer drops events when the Redis stream's MAXLEN trims unread entries. Looking into the issue, redis operations or stream consumer pipelines need robust handling around timeouts, atomic TTL expiration, and consumer group PEL retention. My plan is to audit the redis transaction or pipeline operations to guarantee atomic key creation and ttl assignment, ensure consumer group acknowledgment and stream retention parameters prevent unexpected data loss, and ensure propagate configured timeout deadlines cleanly across pipelined commands.
For testing, I'll simulate high-throughput or network delay scenarios to verify bounded memory and zero dropped entries.
Please assign this to me and I'll submit the PR with passing CI.
I reviewed the issue for Indexer drops events when the Redis stream's MAXLEN trims unread entries. Redis operations or stream consumer pipelines need robust handling around timeouts, atomic ttl expiration, and consumer group pel retention.
Proposed Implementation:
Audit the Redis transaction or pipeline operations to guarantee atomic key creation and TTL assignment.
Ensure consumer group acknowledgment and stream retention parameters prevent unexpected data loss.
Propagate configured timeout deadlines cleanly across pipelined commands.
Testing & Verification:
I will simulate high-throughput or network delay scenarios to verify bounded memory and zero dropped entries.
Please assign this to me and I will deliver a clean PR with passing tests shortly.
Activity
GangDev6707 commentedon Nov 2, 2026
Hi maintainers,
I'd like to help resolve this issue. Redis operations or stream consumer pipelines need robust handling around timeouts, atomic ttl expiration, and consumer group pel retention. I plan to audit the redis transaction or pipeline operations to guarantee atomic key creation and ttl assignment and ensure consumer group acknowledgment and stream retention parameters prevent unexpected data loss, followed by propagate configured timeout deadlines cleanly across pipelined commands.
I'll simulate high-throughput or network delay scenarios to verify bounded memory and zero dropped entries to verify everything passes cleanly.
Happy to take this on if you can assign it over. Will get a clean PR ready promptly.
ranjan1969x commentedon Nov 2, 2026
Hello maintainers,
I reviewed the requirements for Indexer drops events when the Redis stream's MAXLEN trims unread entries. Looking into the issue, redis operations or stream consumer pipelines need robust handling around timeouts, atomic TTL expiration, and consumer group PEL retention. My plan is to audit the redis transaction or pipeline operations to guarantee atomic key creation and ttl assignment, ensure consumer group acknowledgment and stream retention parameters prevent unexpected data loss, and ensure propagate configured timeout deadlines cleanly across pipelined commands.
For testing, I'll simulate high-throughput or network delay scenarios to verify bounded memory and zero dropped entries.
Please assign this to me and I'll submit the PR with passing CI.
maxx-GENIUS commentedon Nov 6, 2026
Hey team,
I reviewed the issue for Indexer drops events when the Redis stream's MAXLEN trims unread entries. Redis operations or stream consumer pipelines need robust handling around timeouts, atomic ttl expiration, and consumer group pel retention.
Proposed Implementation:
Testing & Verification:
I will simulate high-throughput or network delay scenarios to verify bounded memory and zero dropped entries.
Please assign this to me and I will deliver a clean PR with passing tests shortly.