Ravindra BagaleCourses & study guides मराठी Track your progress

Ravi Sir's Cards › AWS

Idempotent receipts

What is a VPC: your own private network inside one AWS Region, example ThreeTierVpc 10.0.0.0/16.

Idempotent receipts S3 can retry the same ObjectCreated event. Double email confuses users. Idempotent = doing the same work twice is safe. Key the DynamoDB receipt by object versionId or etag; skip if already sent. PutItem with condition attribute_not_exists(receiptId) or GetItem first; only then SendEmail. Two deliveries of the same event → one email, one DynamoDB row.
Idempotent receipts · Download PNG
Read card text

What this card says

Why do we need it?

S3 can retry the same ObjectCreated event. Double email confuses users.

What is it?

Idempotent = doing the same work twice is safe. Key the DynamoDB receipt by object versionId or etag; skip if already sent.

How to do it

PutItem with condition attribute_not_exists(receiptId) or GetItem first; only then SendEmail.

attribute_not_exists

Example

Two deliveries of the same event → one email, one DynamoDB row.

See all AWS revision cards