Skip to content

feature aws lambda durable functions nodejs saga pattern#2961

Open
dsiz wants to merge 5 commits intoaws-samples:mainfrom
dsiz:dsiz-feature-aws-lambda-durable-functions-nodejs-saga-pattern
Open

feature aws lambda durable functions nodejs saga pattern#2961
dsiz wants to merge 5 commits intoaws-samples:mainfrom
dsiz:dsiz-feature-aws-lambda-durable-functions-nodejs-saga-pattern

Conversation

@dsiz
Copy link
Contributor

@dsiz dsiz commented Feb 19, 2026

Issue #, if available:

Description of changes:

aws lambda durable functions nodejs saga pattern

By submitting this pull request, I confirm that you can use, modify, copy, and redistribute this contribution, under the terms of your choice.

@bfreiberg bfreiberg added the durable functions Pattern for AWS Lambda durable functions label Feb 19, 2026
@bfreiberg
Copy link
Contributor

Please make sure to use the correct capitalization: It's Lambda durable functions not Lambda Durable Functions

@dsiz
Copy link
Contributor Author

dsiz commented Feb 19, 2026

@bfreiberg it is just the title that has Lambda Durable Functions (following similar syntax all across other titles and blogs). The content follows "Lambda durable functions". Let me know if you want me to change the title as well

@dsiz
Copy link
Contributor Author

dsiz commented Feb 20, 2026

Modified as per recommendations @bfreiberg

try {
// Step 1: Reserve Flight
const flight = await context.step('reserveFlight', async () => {
console.log('Reserving flight...');
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Please change all console.log to context.logger (see https://github.com/aws/aws-durable-execution-sdk-js/tree/main)

}
},
"resources": {
"bullets": [
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Please include a link to the Lambda Durable Execution SDK

## How durable functions Enable Saga Pattern

1. **State Management**: `context.step()` automatically checkpoints each operation
2. **Idempotency**: Steps are executed exactly once, even on retries
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
2. **Idempotency**: Steps are executed exactly once, even on retries
2. **Idempotency**: Completed steps are executed exactly once, even on retries


## How durable functions Enable Saga Pattern

1. **State Management**: `context.step()` automatically checkpoints each operation
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
1. **State Management**: `context.step()` automatically checkpoints each operation
1. **State Management**: `context.step()` automatically creates checkpoints when completing the operation


- [AWS Lambda durable functions](https://docs.aws.amazon.com/lambda/latest/dg/durable-functions.html)
- [Saga Pattern](https://microservices.io/patterns/data/saga.html)
- [Distributed Transactions](https://aws.amazon.com/blogs/compute/building-a-serverless-distributed-application-using-a-saga-orchestration-pattern/)
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Copyright footer is missing

… link, update README text, and add copyright footer
@dsiz
Copy link
Contributor Author

dsiz commented Feb 23, 2026

@bfreiberg made the suggested changes.

@dsiz dsiz requested a review from bfreiberg February 23, 2026 04:48
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

durable functions Pattern for AWS Lambda durable functions

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants