ExitAWS Lambda: event-driven automation1 / 9
Explanation

From an event to a resource change

How service and alarm events invoke Lambda handlers that use execution roles to change AWS resources safely despite retries and duplicate events. · associate

AWS Lambda runs a handler when an event invokes the function. The handler receives event data, decides whether action is needed, and calls AWS APIs. You provide the code; Lambda manages the compute that runs it.

This architecture accepts both CloudWatch alarm state changes and EC2 instance state changes through EventBridge. Its automation reads an approved instance and sets a fixed remediation tag. The diagram shows event delivery, role permissions, and automation calls; it omits API responses and telemetry.

Alarm state eventInstance state eventMatching eventRole permissionsClaim and recordRead and tag
Amazon CloudWatchAlarm state changes
Amazon EC2Managed instances
Amazon EventBridgeFiltered event rules
AWS LambdaValidate and remediate
AWS Identity and Access Management (IAM)Lambda execution role
Amazon DynamoDB tableOperation claims and outcomes

1 / 6 CloudWatch produces alarm state-change events. EC2 produces instance state-change events; either can provide the signal for this automation.

AWS architecture icons are the property of Amazon Web Services. BlowStack is not affiliated with or endorsed by AWS.