A company is designing an automated serverless workflow to coordinate its customer onboarding process. The workflow must execute several steps, including identity verification, account creation, and waiting for the customer to upload a signed agreement, which can take up to 5 days. The processing logic for each step is short-lived, completing in under 2 seconds. The initial onboarding requests must be processed in the exact order they are received to prevent race conditions. The company wants to minimize compute and database costs, ensuring that they do not pay for idle resources while waiting for the customer's document. Which architecture should a solutions architect recommend to meet these requirements?
- Configure an Amazon SQS FIFO queue to ingest the requests. Use an AWS Step Functions Standard Workflow to coordinate the onboarding process, invoking AWS Lambda functions for individual tasks, and pause the workflow using a task token callback until the signed document is uploaded.Answer
- BConfigure an Amazon SQS standard queue to ingest the requests. Use an AWS Step Functions Standard Workflow to coordinate the onboarding process, invoking AWS Lambda functions for individual tasks, and pause the workflow using a task token callback until the signed document is uploaded.
- CConfigure an Amazon SQS FIFO queue to ingest the requests. Develop a single AWS Lambda function that executes the onboarding steps and uses an internal polling loop to check daily for the uploaded document until the onboarding process is complete.
- DConfigure an Amazon SQS FIFO queue to ingest the requests. Use an AWS Step Functions Standard Workflow to coordinate the onboarding process, storing step metadata in an Amazon DynamoDB table configured with provisioned capacity.
Answer
Configure an Amazon SQS FIFO queue to ingest the requests, use an AWS Step Functions Standard Workflow to coordinate the onboarding process with task token callbacks to pause execution, and use AWS Lambda for short-lived tasks.
The correct architecture uses an Amazon SQS FIFO queue to guarantee the ordering of incoming requests, and orchestrates the multi-day onboarding process using an AWS Step Functions Standard Workflow. Standard Workflows are billed per state transition and can run for up to a year, making them highly cost-effective because the system does not pay for compute resources while waiting for the customer's signed document. Individual short-lived tasks are executed by AWS Lambda, which scales to zero and only bills for active execution time.
Step-by-Step Solution
Key Concept
Integrating Amazon SQS FIFO queues with AWS Step Functions Standard Workflows allows orchestrating order-sensitive, long-running processes serverlessly without paying for idle compute time.
Estimated Time:2m 0s