Monitor AWS Lambda Functions Deployed Using Container Images | Datadog

Monitor AWS Lambda functions deployed using container images

Author Stephen Pinkerton

Published: December 1, 2020

The serverless ecosystem has changed dramatically since it first began gaining popularity with developers who want a faster, easier way to deploy their applications. Today, it has matured into a compelling strategy for building modern, enterprise-scale products. But, as more and more organizations adopt rapidly changing technologies, developers are often left with gaps in visibility between key applications. This makes migrating to containers or serverless architectures riskier, full of unknowns, and more time consuming.

We built Datadog Serverless Monitoring to help companies get end-to-end visibility across their serverless infrastructure, even as the ecosystem continues to expand. Today, AWS Lambda announced support for deploying functions packaged as container images, which means that even more companies can leverage the benefits of serverless while continuing to use their existing container tools and development environments. Datadog’s Lambda integration now includes support for functions packaged as container images, so you can seamlessly monitor the health of all your services in one platform, even as your dynamic environment evolves.

Out-of-the-box aws lambda enhanced metrics dashboard

Add serverless to your stack without sacrificing visibility

Containers let you isolate your microservices and create consistent, reproducible environments across development, staging, and production. Packaging code into container images is nothing new. In fact, our research shows that container usage has never been more prevalent. But what happens when you add AWS Lambda functions to the mix?

Packaging AWS Lambda functions as container images is simple and does not require you to swap out your existing tools. For example, AWS Lambda-provided open source base images for Node.js, Python, Ruby, Go, Java, and .NET Core are available on Docker Hub. Alternatively, you can use a community-provided image or even start from scratch. To deliver visibility into the health of your stack, Datadog Serverless Monitoring is equipped to monitor any kind of AWS Lambda function, including functions deployed using container images.

To start monitoring a Lambda function deployed using a container image, simply install the Datadog Lambda Library for your runtime directly within the container. For example, if your function is using the Python runtime, you can run pip install datadog-lambda to install the Datadog Lambda Library for Python. See the documentation for more details.

Correlate traces, logs, and metrics across any kind of infrastructure

Datadog can trace distributed requests, collect logs, and ingest metrics from any combination of infrastructure components—and then correlate them automatically, giving you a single place to understand the health of your system.

This means that even if you use Docker, Kubernetes, and Terraform today to manage your infrastructure, you could decide to build and run a new service on AWS Lambda with the same tools, and then immediately start monitoring it with Datadog. With Datadog’s end-to-end distributed tracing and automatic log correlation, you won’t see any gaps as you introduce a new AWS Lambda-based service that scales automatically in response to new requests.

Datadog Serverless Monitoring provides end-to-end visibility across your serverless architecture in one platform.

Monitor any AWS Lambda environment at any scale

As you deploy applications across a heterogenous mixture of VMs, containers, and serverless functions, it can be challenging to navigate that complexity without comprehensive monitoring. Datadog’s AWS Lambda integration provides end-to-end visibility across all these disparate components—including any functions deployed using container images—so you can seamlessly troubleshoot issues and monitor what ultimately matters most: how well your applications are serving your customers.

If you’re already using Datadog, check out our documentation to begin monitoring any Lambda function deployed as a container image. Otherwise, get started with a 14-day full-featured today.