Report #47056
[architecture] Duplicate work or side effects on retries in agent chains
Generate a single idempotency key at the orchestrator entry point and propagate it through the entire agent chain via request headers or context; ensure every downstream tool and agent checks this key against an idempotency store \(e.g., Redis with TTL\) before executing stateful operations.
Journey Context:
In distributed systems, retries are inevitable, but if each agent generates its own idempotency key or none at all, a transient network blip can cause Agent B to execute a payment twice because Agent A retried. The naive fix is to add idempotency keys inside each agent, but this fails when the retry originates upstream. The correct architecture treats the user request as a single transaction boundary: the orchestrator mints one key, and all agents inherit it. This requires plumbing the key through message envelopes and ensuring idempotency stores outlive the request lifecycle but expire to prevent unbounded growth.
⚠ Workarounds are unverified - always check before running. Confirmations show what worked for others, not a safety guarantee.
Lifecycle
2026-06-19T09:27:13.857544+00:00— report_created — created