Skip to content

Commit 4db4c67

Browse files
committed
docs(idempotency): note to skip timeout section when using handler decorator
Signed-off-by: heitorlessa <lessa@amazon.co.uk>
1 parent 9257196 commit 4db4c67

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

docs/utilities/idempotency.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -299,14 +299,14 @@ Imagine the function runs successfully, but the client never receives the respon
299299

300300
### Lambda timeouts
301301

302+
!!! note "You can skip this section if you are using the [`@idempotent` decorator](#idempotent-decorator)"
303+
302304
By default, we protect against [concurrent executions](#handling-concurrent-executions-with-the-same-payload) with the same payload using a locking mechanism. However, if your Lambda function times out before completing the first invocation it will only accept the same request when the [idempotency record expire](#expiring-idempotency-records).
303305

304306
To prevent extended failures, use **`register_lambda_context`** function from your idempotency config to calculate and include the remaining invocation time in your idempotency record.
305307

306308
=== "Registering the Lambda context"
307309

308-
> This is unnecessary for [`@idempotent` decorator](#idempotent-decorator), as it captures the Lambda context from your handler function.
309-
310310
```python title="working_with_lambda_timeout.py" hl_lines="11 20"
311311
--8<-- "examples/idempotency/src/working_with_lambda_timeout.py"
312312
```

0 commit comments

Comments
 (0)