MCPcopy Index your code
hub / github.com/DataDog/datadog-lambda-go

github.com/DataDog/datadog-lambda-go @v1.32.0

Chat with this repo
repository ↗ · DeepWiki ↗ · release v1.32.0 ↗ · + Follow
307 symbols 1,018 edges 35 files 84 documented · 27% 2 cross-repo links
What it actually does AI analysis from the code graph — generated when you open this
loading…
README

datadog-lambda-go

build Code Coverage Slack Godoc License

IMPORTANT NOTICE: This repository is being deprecated. The library has been migrated to https://github.com/DataDog/dd-trace-go/tree/main/contrib/aws/datadog-lambda-go. See the migration instructions for more guidance.

Datadog Lambda Library for Go enables enhanced Lambda metrics, distributed tracing, and custom metric submission from AWS Lambda functions.

Installation

Follow the installation instructions, and view your function's enhanced metrics, traces and logs in Datadog.

Configurations

See the advanced configuration options to tag your telemetry, capture request/response payloads, filter or scrub sensitive information from logs or traces, and more.

Opening Issues

If you encounter a bug with this package, we want to hear about it. Before opening a new issue, search the existing issues to avoid duplicates.

When opening an issue, include the datadog-lambda-go version, go version, and stack trace if available. In addition, include the steps to reproduce when appropriate.

You can also open an issue for a feature request.

Contributing

If you find an issue with this package and have a fix, please feel free to open a pull request following the procedures.

Community

For product feedback and questions, join the #serverless channel in the Datadog community on Slack.

License

Unless explicitly stated otherwise all files in this repository are licensed under the Apache License Version 2.0.

This product includes software developed at Datadog (https://www.datadoghq.com/). Copyright 2021 Datadog, Inc.

Extension points exported contracts — how you extend this code

Decrypter (Interface)
Decrypter attempts to decrypt a key [4 implementers]
internal/metrics/kms_decrypter.go
HTTPClient (Interface)
(no doc) [6 implementers]
internal/extension/extension.go
HandlerListener (Interface)
HandlerListener is a point where listener logic can be injected into a handler [3 implementers]
internal/wrapper/wrap_handler.go
ContextExtractor (FuncType)
ContextExtractor is a func type for extracting a root TraceContext.
internal/trace/context.go
Client (Interface)
Client sends metrics to Datadog [2 implementers]
internal/metrics/api.go
TimeService (Interface)
TimeService wraps common time related operations [2 implementers]
internal/metrics/time.go
Metric (Interface)
Metric represents a metric that can have any kind of [1 implementers]
internal/metrics/model.go
Processor (Interface)
Processor is used to batch metrics on a background thread, and send them on to a client periodically. [1 implementers]
internal/metrics/processor.go

Core symbols most depended-on inside this repo

Debug
called by 28
internal/logger/log.go
Error
called by 23
internal/logger/log.go
AddMetric
called by 20
internal/metrics/processor.go
Now
called by 13
internal/metrics/time.go
Flush
called by 13
internal/extension/extension.go
MakeListener
called by 12
internal/metrics/listener.go
HandlerStarted
called by 11
internal/wrapper/wrap_handler.go
HandlerFinished
called by 11
internal/wrapper/wrap_handler.go

Shape

Function 178
Method 75
Struct 39
Interface 8
TypeAlias 6
FuncType 1

Languages

Go100%

Modules by API surface

internal/extension/extension_test.go46 symbols
internal/wrapper/wrap_handler_test.go25 symbols
internal/trace/context_test.go23 symbols
internal/trace/context.go16 symbols
ddlambda.go16 symbols
internal/metrics/listener_test.go15 symbols
internal/metrics/processor.go14 symbols
internal/metrics/processor_test.go12 symbols
internal/metrics/model.go12 symbols
internal/metrics/listener.go12 symbols
internal/extension/extension.go12 symbols
internal/metrics/api.go11 symbols

Used by 2 indexed graphs manifest dependencies, hub-wide

For agents

$ claude mcp add datadog-lambda-go \
  -- python -m otcore.mcp_server <graph>

⬇ download graph artifact