This Instrumentation Rule is currently only available with the Odigos Enterprise plan.
Contact us for more information.

Considerations

Before enabling headers collection, please note the following:

  • The support for headers collection varies between instrumentation libraries and languages.
  • HTTP headers might contain PII data (like cookies or API keys), thus it is recommended to review each requested header before configuring it to avoid sensitive information.

Configuration Options

Any unspecified headers will not be recorded.

Basic Example

The following example demonstrates how to enable headers collection for all supported workloads and instrumentation libraries in the cluster.

1

Create a YAML file with the following content:

headers-collection.yaml
apiVersion: odigos.io/v1alpha1
kind: InstrumentationRule
metadata:
  name: collect-all-headers
  namespace: odigos-system
spec:
  ruleName: "collect all supported headers"
  headersCollection:
    headerKeys: ["*"]
2

Apply the action to the cluster:

kubectl apply -f headers-collection.yaml