Lambda automatically integrates with CloudWatch Logs and pushes all logs from our code to a CloudWatch Logs group associated with a Lambda function, which is named /aws/lambda/<function name>. We can view logs for Lambda by using the Lambda console, the CloudWatch console, the AWS CLI, or the CloudWatch API. Subscription Filters with Sumo Logic CloudWatch Logs Lambda Function. Currently CloudWatch Lambda function provides a Log Group (SumoCWLogGroup) which has a subscription filter (SumoCWLogSubsriptionFilter) associated with it. Now consider these scenarios, currently you have a log group /var/log/syslog from EC2 instance and now you have added ... When CloudTrail logging is turned on, CloudWatch Events writes log files to an S3 bucket. Each log file contains one or more records, depending on how many actions are performed to satisfy a request. The AWS Lambda function designer panel lets you select which services can trigger the function and which services the function can access while running. We're going to use SNS (Simple Notification Service) and CloudWatch Events as triggers with Amazon Pinpoint and Amazon CloudWatch Logs during execution. The Lambda function needs permissions to query ECS and then write to CloudWatch Logs and metrics. When you create the state machine, Lambda function, and CloudWatch Events rule, you assign this role to each of those resources.