Datadog Lambda Extension (Preview)
New announcements from Dash: Incident Management, Continuous Profiler, and more! New announcements from Dash!

Datadog Lambda Extension (Preview)

Overview

The Datadog AWS Lambda Extension is in public preview. If you have any feedback, contact Datadog support.

AWS Lambda Extensions are companion processes that augment your Lambda functions. They run within the Lambda execution environment, alongside your Lambda function code. The Datadog Extension is a lightweight version of the Datadog agent built to run alongside your code with minimal performance overhead.

The Datadog Extension currently supports submitting custom metrics synchronously while your AWS Lambda function executes. This means that you can submit your custom metrics without the Datadog Forwarder. Note that the Datadog Forwarder is still required to submit logs and traces to Datadog.

Setup

The Datadog Extension is distributed as its own Lambda Layer (separate from the Datadog Lambda Library) and supports Node.js, Python, and Go runtimes.

  1. Instrument your Python, Node.js, or Go application.

  2. Add the Lambda Layer for the Datadog Extension to your AWS Lambda function:

    arn:aws:lambda:<AWS_REGION>:464622532012:layer:Datadog-Extension:3
    

    Replace the placeholder AWS_REGION in the Lambda Layer ARN with appropriate values.

  3. If you are using Node.js or Python, add the Lambda Layer for the Datadog Library to your AWS Lambda function:

    arn:aws:lambda:<AWS_REGION>:464622532012:layer:Datadog-<RUNTIME>:<VERSION>
    

    The available RUNTIME options are Node8-10, Node10-x, Node12-x, Python27, Python36, Python37, and Python38. For VERSION, see the latest release for Node.js or Python.

  4. Reference the sample code to submit a custom metric.

Further Reading

Additional helpful documentation, links, and articles: