Integrate OpenTelemetry on AWS Lambda
Dynatrace uses OpenTelemetry to monitor AWS Lambda invocations. See below for instructions.
Note: In combination with the default OpenTelemetry SDKs and APIs, you can use language-specific packages, such as Integrate OpenTelemetry .NET on AWS Lambda.
Prerequisites
Dynatrace version 1.240+-
Activate the Forward Tag 4 trace context extension OneAgent feature. In the Dynatrace menu, go to Settings > Preferences > OneAgent features.
Note: All OneAgents participating in a trace be OneAgent version 1.193+ for this setting.
1. Get started
You can activate AWS Lambda from either the Dynatrace Hub or the Deploy Dynatrace page.
- In the Dynatrace menu, go to Dynatrace Hub.
- Find and select AWS Lambda.
- Select Activate AWS Lambda.
Note: Configuration options regarding Lambda layers don't apply here.
- In the Dynatrace menu, go to Deploy Dynatrace.
- Select Start installation.
- Select AWS Lambda.
Note: Configuration options regarding Lambda layers don't apply here.
2. Choose a configuration method
On Enable Monitoring for AWS Lambda Functions, under Select a configuration method, select your preferred configuration method from the dropdown menu. Make sure you set all properties for the selected method before copying the generated configuration snippets.
Note: Only Configure with environment variables and Configure with JSON file are applicable here.
3. Specify a Dynatrace API endpoint optional
Specify a Dynatrace API endpoint where you want to receive monitoring data. Typically, to reduce network latency, you deploy a Dynatrace ActiveGate close to (the same region as) the AWS Lambda function that you want to monitor.
4. Instrument the function code
Adding the required API calls to monitor function invocations via OpenTelemetry is specific to languages and their respective OpenTelemetry distribution.
To get detailed instructions for different languages supported by Dynatrace, see Integrate OpenTelemetry .NET on AWS Lambda.
Known limitations
The Dynatrace AWS Lambda integration doesn't capture IP addresses of outgoing HTTP requests. This results in unmonitored hosts if the called service isn't monitored with Dynatrace OneAgent.