Amazon Bedrock Async Invoke with AWS Lambda durable functions

Amazon SQS → AWS Lambda durable function

Orchestrate long-running Amazon Bedrock video generation jobs using AWS Lambda durable functions with waitForCondition polling and zero-cost waits

This pattern deploys an AWS Lambda durable function that orchestrates Amazon Bedrock Async Invoke to generate AI videos using Amazon Nova Reel.
The durable function starts a video generation job with StartAsyncInvoke, then polls for completion using waitForCondition with exponential backoff. During each polling interval the function suspends entirely, incurring zero compute charges while Bedrock processes the video.
An S3 bucket is provisioned for video output. The durable execution SDK checkpoints progress at each step, so the workflow is fault-tolerant and idempotent without requiring external orchestration.

< Back to all patterns

GitHub icon Download this pattern (.zip)

GitHub icon View this pattern on GitHub


Clone repo

git clone https://github.com/aws-samples/serverless-patterns/cd serverless-patterns/lambda-durable-bedrock-async-invoke-cdk

Deploy

npm installnpx cdk deploy


Testing

See the GitHub repo for detailed testing instructions.

Cleanup

Delete the stack: npx cdk destroy.

Created by:

Ben Freiberg

Ben Freiberg

Ben is a Senior Solutions Architect at Amazon Web Services (AWS) based in Frankfurt, Germany.

Follow on LinkedIn

Michael Gasch

Michael Gasch

Senior Product Manager Technical for Amazon EventBridge.

Follow on LinkedIn