Circuit Breaker Pattern for Amazon Bedrock Pipeline Failures
A global company runs an AI-powered document-processing pipeline that uses Amazon Bedrock to summarize text documents. The pipeline occasionally times out during peak traffic periods. The timeouts cause service degradation. The company needs a solution to detect when error rates exceed 10% within any 60-second window. The solution must switch to an alternate process path when the error rate threshold is exceeded. The solution must automatically resume normal Amazon Bedrock processing when the pipeline recovers. The company must ensure that the pipeline processes all documents within 15 minutes. Which solution will meet these requirements?
Community Insight
The question tests the circuit breaker pattern for a Bedrock pipeline; the common trap is choosing custom DynamoDB failure tracking over CloudWatch's native alarm and EventBridge-driven automation.
This question tests how to implement an automated circuit breaker for an Amazon Bedrock document-processing pipeline using AWS Step Functions, CloudWatch alarms, and EventBridge. The correct solution uses a CloudWatch alarm to detect error-rate thresholds and EventBridge to automatically switch traffic, ensuring recovery without manual intervention.
Learners often choose Option A, which implements circuit-breaker logic via DynamoDB, because it uses the term 'circuit breaker pattern.' However, CloudWatch alarms natively handle threshold-based detection (10% over 60 seconds) and EventBridge provides event-driven switching—making Option C more idiomatic, scalable, and fully automated.
Community Discussion (1 comments)
Comments & Corrections
No comments yet — spotted an error or have a note? Share it below.
Expert Analysis
Why the Answer Is Correct
Option C correctly combines an AWS Step Functions state machine with Retry/Catch logic for resilient Bedrock invocations, a CloudWatch alarm to detect when error rates exceed 10% within any 60-second evaluation window, and an EventBridge rule to automatically redirect traffic to the alternate processing path. CloudWatch alarms natively support percentage-based thresholds over configurable windows, precisely matching the requirement. When the alarm transitions back to OK state, the EventBridge rule can trigger a return to the normal Bedrock path, satisfying the automatic-recovery requirement. This is the standard AWS architectural pattern for circuit breaking at the monitoring and event-routing layer.Why the Other Options Are Wrong
Option A tracks failures in DynamoDB and routes based on that state—functional but ad hoc—requiring custom logic to evaluate the 10%/60-second threshold and manage recovery state manually within Step Functions. Option B requires company staff to manually update the workflow, which violates the automatic-resume requirement. Option D deploys multiple state machines behind API Gateway with a health-check Lambda routing to the fastest responder—this adds complexity but does not detect the specific 10% error-rate threshold or implement a true circuit breaker with automatic recovery.Community Comment Notes
TNT87 voted for Option A, arguing the circuit breaker pattern with DynamoDB is the standard architectural method. However, while DynamoDB-based tracking is a valid implementation detail, it requires more custom code to evaluate the specific 10%/60-second threshold and manage recovery. CloudWatch alarms (Option C) handle this out of the box and pair naturally with EventBridge for event-driven automation, making C the more idiomatic AWS solution.Official Reference
Exam Strategy
On AWS architecture questions, prefer solutions that use managed, native AWS services (CloudWatch alarms, EventBridge) over custom tracking logic—managed services handle threshold detection and event-driven automation more reliably and with less code. Always verify that the option fully automates both failure detection AND recovery with no manual steps.
Frequently Asked Questions
Why not use DynamoDB to track Bedrock failures as a circuit breaker?
Option A's DynamoDB approach is valid but requires custom logic to evaluate the 10%/60-second threshold. CloudWatch alarms natively detect this and EventBridge automates switching, reducing complexity.
Does Option C automatically resume Bedrock processing after recovery?
Yes. When the CloudWatch alarm returns to OK, the EventBridge rule can trigger a state transition back to the normal Bedrock path, satisfying the automatic-recovery requirement.
Related Analysis
Practice All AIP-C01 Questions
Access 110 questions with complete answers and detailed explanations.
View Full AIP-C01 Practice Test →