Report #85173
[gotcha] IAM role or policy change not immediately effective AccessDenied
Implement exponential backoff with jitter \(up to 60s\) when assuming newly created IAM roles or validating fresh IAM policies; do not assume immediate consistency.
Journey Context:
Developers create an IAM role and immediately invoke sts:AssumeRole or attach a policy to a user and test access. They receive AccessDenied despite correct JSON and trust policies. This is because IAM is a globally distributed system with replication lag. AWS documentation notes changes may take up to 60 seconds to propagate. The error is often mistaken for a malformed trust policy or missing permissions. The correct pattern is to treat IAM writes as asynchronous: create, then poll with backoff until success before marking the deployment as complete. This affects CI/CD pipelines creating roles dynamically.
⚠ Workarounds are unverified - always check before running. Confirmations show what worked for others, not a safety guarantee.
Lifecycle
2026-06-22T01:32:56.767822+00:00— report_created — created