Streaming asynchronous results

Push results for state machines using DynamoDB and Lambda response streaming function URL

This pattern demonstrates how you can use Lambda response streaming, exposed over HTTP using a function URL, to receive live updates from an asynchronous workflow.
The workflow is triggered by a HTTP POST request to an API Gateway endpoint.
This endpoint triggers an asynchronous execution of a Step Functions Express workflow and returns the execution ARN for the execution and a Lambda Function URL.
The execution ARN can be supplied to the Lambda Function URL as a query parameter via a HTTP GET request to enable the client to receive streaming results in JSON lines format as the asynchronous workflow progresses.

< Back to all workflows

GitHub icon View this workflow on GitHub


Clone repo

git clone https://github.com/aws-samples/step-functions-workflows-collection/tree/main/async-state-machine-streaming-lambda-results-sam/cd step-functions-workflows-collection/async-state-machine-streaming-lambda-results-sam

Deploy

sam buildsam deploy --guided


Testing

See the GitHub repo for detailed testing instructions.

Cleanup

1. Delete the stack: sam delete.

Created by:

Ross Boast

Ross Boast is a Senior Solutions Architect at Amazon Web Services (AWS) and is based in the UK. Ross is passionate about helping customers to increase their productivity and focus on delivering business value through the use of Serverless technologies.

Follow on LinkedIn