Built-in Configuration

Built-in Configuration

Orchestrion includes built-in configuration that automatically instruments many libraries using the Datadog tracing library, gopkg.in/DataDog/dd-trace-go.v1.

These automated instrumentations are modeled as aspects, which are the combination of:

  • a join point, which is a standardized description of the location where instrumentation code is to be added,
  • one or more advice, which describe the modifications to be made.

The following pages highlights what libraries are supported, how instrumentation is achieved, and any caveats or limitations to be aware of:

//dd:orchestrion-enabled
Flip a boolean to true if Orchestrion is enabled.
//dd:span
Create a span surrounding all calls to the annotated function by adding a `//dd:span` directive on the function declaration. The default operation (span) name is the name of the function, but this can be overridden by specifying a `span.name` argument: ```go //dd:span span.name:custom-operation-name other:tag func myFunction() { // The default operation name would have been "myFunction" } ``` Function literal expressions don't have a function name, and their default operation name is the value of the very first directive argument (if there is one). If there are no directive arguments, the operation name will remain blank. ```go //dd:span other:tag span.name:custom-operation-name myOp := func() { // The default operation name would have been "tag" } ```
database/sql
A generic interface around SQL (or SQL-like) databases.
func main()
The entry point of a Go program.
github.com/aws/aws-sdk-go
The official AWS SDK for Go
github.com/aws/aws-sdk-go-v2
AWS SDK for the Go programming language.
github.com/gin-gonic/gin
Gin is a web framework written in Go.
github.com/go-chi/chi
chi is a lightweight, idiomatic and composable router for building Go HTTP services.
github.com/go-redis/redis
Redis client for Go.
github.com/gocql/gocql
Package gocql implements a fast and robust Cassandra client for the Go programming language.
github.com/gofiber/fiber
An Express inspired web framework built on Fasthttp, the fastest HTTP engine for Go.
github.com/gomodule/redigo/redis
Redigo is a Go client for the Redis database.
github.com/gorilla/mux
Package gorilla/mux implements a request router and dispatcher for matching incoming requests to their respective handler.
github.com/hashicorp/vault/api
Official package for interacting with a Vault server.
github.com/IBM/sarama
Sarama is a Go library for Apache Kafka
github.com/labstack/echo
High performance, extensible, minimalist Go web framework.
github.com/Shopify/sarama
Sarama is a Go library for Apache Kafka
go.mongodb.org/mongo-driver/mongo
Official Golang driver for MongoDB.
google.golang.org/grpc
The Go implementation of gRPC.
gorm.io/gorm and github.com/jinzhu/gorm
The fantastic ORM library for Golang.
k8s.io/client-go
Go client for Kubernetes.
log/slog
log/slog logger
net/http.Client
HTTP client implementation.
net/http.Server
HTTP server implementation.
os
Protection from Local File Inclusion (LFI) Attacks All known functions that open files are susceptible to Local File Inclusion (LFI) attacks. This aspect protects against LFI attacks by wrapping the `os.OpenFile` function with a security operation that will block the operation if it is deemed unsafe. Instrumenting only the `os.OpenFile` function is sufficient to protect against LFI attacks, as all other functions in the `os` package that open files ultimately call `os.OpenFile` (as of Go 1.23).
runtime
Operations that interact with Go's runtime system.
Last updated on