Which AWS service should be used to trigger an AWS Lambda function when an Amazon EC2 instance transitions to the “stopping” state?
Choose an answer
Tap an option to check your answer.
Correct answer: Amazon EventBridge.
Why this is the answer
Amazon EventBridge is the correct choice because it allows you to create rules that react to events from AWS services, including state changes for Amazon EC2 instances. You can configure an EventBridge rule to detect when an EC2 instance enters the "stopping" state and then trigger a target, such as an AWS Lambda function, to perform automated actions. AWS Config is incorrect because it primarily focuses on auditing and evaluating the configurations of your AWS resources, not directly triggering actions based on real-time state changes. Amazon SNS is a messaging service used for publishing messages to subscribers, but it doesn't natively monitor EC2 instance state changes to trigger actions. AWS CloudFormation is an infrastructure as code service for provisioning and managing AWS resources, not for event-driven automation.
Pass your exam — without the endless answer hunt
Get every verified question and explanation for this exam in one place, and save hours of prep. 1,000+ certifications · 20+ languages · free to start.
Pass your exam faster → No card needed