1 Answer
- Newest
- Most votes
- Most comments
0
Hello,
Lambda does not provide a way to specify a custom log group target. A log group is automatically created on the first invocation of a Lambda and the log group name will contain the name of the Lambda function.
When log streams are created however, the function version is prefixed onto the name of the log stream. You can use a log stream filter to view log streams for a specific version.
If you want to know which alias invoked a particular version of a Lambda, the alias ARN is included in the Lambda context object as:
context.invoked_function_arn
You can use the print method to write the ARN into the log event.
Best,
Kevin
answered 4 years ago
Relevant content
- asked 2 years ago
- asked 10 months ago
- asked 2 years ago
- AWS OFFICIALUpdated 3 years ago
- AWS OFFICIALUpdated 2 months ago
- AWS OFFICIALUpdated a year ago