Skip to content

Commit 41a8be2

Browse files
authored
[obi] - add context propagation (#237)
* add context propagation * update changelog * enable context propagation in CM
1 parent 95b60cb commit 41a8be2

6 files changed

Lines changed: 50 additions & 5 deletions

File tree

charts/opentelemetry-ebpf-instrumentation/CHANGELOG.md

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,11 @@
22

33
## OpenTelemetry eBPF Instrumentation
44

5+
### v0.1.2 / 2025-07-13
6+
- [Feat] Add context propagation value in `values.yaml` ([port from beyla](https://github.com/grafana/beyla/commit/37749b58ef616bbb304216ee5407ba95bae9c6fb))
7+
- [Feat] Change default values to add redis db cache, k8s cache and mysql large buffers
8+
- [Feat] Change default of attributes.kubernetes.enabled to true
9+
510
### v0.1.1 / 2025-06-17
611
- [Feat] Use new `otel/opentelemetry-ebpf-k8s-cache` image instead of beyla one
712
- [Fix] rename `otel-ebpf-k8s-cache` to `opentelemetry-ebpf-instrumentation-k8s-cache`
Lines changed: 15 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,15 @@
1+
2+
#####################################################
3+
#
4+
# List of approvers for OpenTelemetry eBPF Instrumentation Helm
5+
#
6+
#####################################################
7+
#
8+
# Learn about membership in OpenTelemetry community:
9+
# https://github.com/open-telemetry/community/blob/main/community-membership.md
10+
#
11+
#
12+
# Learn about CODEOWNERS file format:
13+
# https://help.github.com/en/articles/about-code-owners
14+
#
15+
* @coralogix/anemia
Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
---
22
apiVersion: v2
33
name: opentelemetry-ebpf-instrumentation
4-
version: 0.1.1
4+
version: 0.1.2
55
description: OpenTelemetry eBPF instrumentation Helm chart for Kubernetes
66
type: application
77
home: https://opentelemetry.io/
@@ -11,4 +11,4 @@ sources:
1111
icon: https://opentelemetry.io/img/logos/opentelemetry-logo-nav.png
1212
maintainers:
1313
- name: nimrodavni78
14-
appVersion: 0.1.1
14+
appVersion: 0.1.2

charts/opentelemetry-ebpf-instrumentation/templates/configmap.yaml

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -18,6 +18,10 @@ metadata:
1818
{{- end }}
1919
data:
2020
ebpf-instrument-config.yml: |
21+
{{- if .Values.contextPropagation.enabled }}
22+
ebpf:
23+
context_propagation: "all"
24+
{{- end }}
2125
{{- if eq .Values.preset "network" }}
2226
{{- if not .Values.config.data.network }}
2327
network:

charts/opentelemetry-ebpf-instrumentation/templates/daemon-set.yaml

Lines changed: 13 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -35,7 +35,7 @@ spec:
3535
{{- if eq .Values.preset "application" }}
3636
hostPID: true
3737
{{- end }}
38-
{{- if or (eq .Values.preset "network") .Values.config.data.network }}
38+
{{- if or (eq .Values.preset "network") .Values.config.data.network .Values.contextPropagation.enabled }}
3939
hostNetwork: true
4040
dnsPolicy: {{ .Values.dnsPolicy }}
4141
{{- end }}
@@ -66,6 +66,9 @@ spec:
6666
- CHECKPOINT_RESTORE
6767
- DAC_READ_SEARCH
6868
- PERFMON
69+
{{- if .Values.contextPropagation.enabled }}
70+
- NET_ADMIN
71+
{{- end }}
6972
{{- with .Values.extraCapabilities }}
7073
{{- toYaml . | nindent 16 }}
7174
{{- end }}
@@ -116,6 +119,10 @@ spec:
116119
volumeMounts:
117120
- mountPath: /etc/ebpf-instrument/config
118121
name: ebpf-instrument-config
122+
{{- if .Values.contextPropagation.enabled }}
123+
- mountPath: /sys/fs/cgroup
124+
name: cgroup
125+
{{- end }}
119126
{{- with .Values.volumeMounts }}
120127
{{- toYaml . | nindent 12 }}
121128
{{- end }}
@@ -143,6 +150,11 @@ spec:
143150
- name: ebpf-instrument-config
144151
configMap:
145152
name: {{ default (include "obi.fullname" .) .Values.config.name }}
153+
{{- if .Values.contextPropagation.enabled }}
154+
- name: cgroup
155+
hostPath:
156+
path: /sys/fs/cgroup
157+
{{- end }}
146158
{{- with .Values.volumes }}
147159
{{- toYaml . | nindent 8 }}
148160
{{- end }}

charts/opentelemetry-ebpf-instrumentation/values.yaml

Lines changed: 11 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -61,10 +61,15 @@ podSecurityContext: {}
6161
# -- If set to false, deploys an unprivileged / less privileged setup.
6262
privileged: true
6363

64+
# -- Enables context propagation support.
65+
contextPropagation:
66+
enabled: true
67+
6468
# -- Extra capabilities for unprivileged / less privileged setup.
6569
extraCapabilities: []
6670
# - SYS_RESOURCE # <-- pre 5.11 only. Allows Opentelemetry eBPF Instrumentation to increase the amount of locked memory.
6771
# - SYS_ADMIN # <-- Required for Go application trace context propagation, or if kernel.perf_event_paranoid >= 3 on Debian distributions.
72+
# - NET_ADMIN # <-- Required to inject HTTP and TCP context propagation information. This will be added when contextPropagation is enabled.
6873

6974
# -- Security context for privileged setup.
7075
securityContext:
@@ -201,13 +206,17 @@ config:
201206
# cloud_zone: prod-eu-west-0
202207
# cloud_instance_id: 123456
203208
# cloud_api_key:
209+
buffer_sizes:
210+
mysql: 4096
211+
redis_db_cache:
212+
enable: true
204213
otel_traces_export:
205214
endpoint: "http://${HOST_IP}:4317"
206215
otel_metrics_export:
207216
endpoint: "http://${HOST_IP}:4318"
208217
attributes:
209218
kubernetes:
210-
enable: false
219+
enable: true
211220
filter:
212221
network:
213222
k8s_dst_owner_name:
@@ -271,7 +280,7 @@ serviceMonitor:
271280
# -- Options to deploy the Kubernetes metadata cache as a separate service
272281
k8sCache:
273282
# -- Number of replicas for the Kubernetes metadata cache service. 0 disables the service.
274-
replicas: 0
283+
replicas: 2
275284
# -- Enables the profile port for the Opentelemetry eBPF Instrumentation cache
276285
profilePort: 0
277286
## Env variables that will override configmap values

0 commit comments

Comments
 (0)