Skip to content

Commit 9f9cf29

Browse files
committed
simplfy available config options
1 parent bb77ea3 commit 9f9cf29

4 files changed

Lines changed: 57 additions & 50 deletions

File tree

charts/sourcegraph/README.md

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -162,7 +162,10 @@ In addition to the documented values, all services also support the following va
162162
| jaeger.collector.serviceAnnotations | object | `{}` | Add extra annotations to jaeger `collector` service |
163163
| jaeger.collector.serviceLabels | object | `{}` | Add extra labels to jaeger `collector` service |
164164
| jaeger.collector.serviceType | string | "ClusterIP" | Kubernetes service type of jaeger `collector` service, learn more from the [Kubernetes documentation](https://kubernetes.io/docs/concepts/services-networking/service/#publishing-services-service-types) |
165-
| jaeger.config | object | `{"exporters":{"jaeger_storage_exporter":{"trace_storage":"main_store"}},"extensions":{"healthcheckv2":{"http":{"endpoint":"0.0.0.0:13133"},"use_v2":true},"jaeger_query":{"base_path":"/-/debug/jaeger","http":{"endpoint":"0.0.0.0:16686"},"storage":{"traces":"main_store"}},"jaeger_storage":{"backends":{"main_store":{"memory":{"max_traces":20000}}}},"remote_sampling":{"file":{"default_sampling_probability":1,"path":"/etc/jaeger/sampling_strategies.json"},"http":{"endpoint":"0.0.0.0:5778"}}},"processors":{"batch":{}},"receivers":{"otlp":{"protocols":{"grpc":{"endpoint":"0.0.0.0:4317"},"http":{"endpoint":"0.0.0.0:4318"}}}},"service":{"extensions":["jaeger_storage","jaeger_query","remote_sampling","healthcheckv2"],"pipelines":{"traces":{"exporters":["jaeger_storage_exporter"],"processors":["batch"],"receivers":["otlp"]}},"telemetry":{"logs":{"level":"info"}}}}` | Jaeger v2 YAML configuration. This is rendered into a ConfigMap and mounted at `/etc/jaeger/jaeger-config.yaml`. Customers can override individual settings (e.g., `max_traces`, sampling) directly in values.yaml. See https://www.jaegertracing.io/docs/2.16/configuration/ |
165+
| jaeger.config | object | `{"logLevel":"info","maxTraces":20000,"samplingDefaultProbability":1}` | Jaeger v2 configuration overrides. These values are templated into a ConfigMap mounted at `/etc/jaeger/jaeger-config.yaml`. See https://www.jaegertracing.io/docs/2.16/configuration/ |
166+
| jaeger.config.logLevel | string | `"info"` | Log level for the Jaeger instance (debug, info, warn, error) |
167+
| jaeger.config.maxTraces | int | `20000` | Maximum number of traces stored in memory |
168+
| jaeger.config.samplingDefaultProbability | float | `1` | Default sampling probability (0.0 to 1.0) returned to services that query Jaeger for sampling config |
166169
| jaeger.containerSecurityContext | object | `{"allowPrivilegeEscalation":false,"readOnlyRootFilesystem":true,"runAsGroup":101,"runAsUser":100}` | Security context for the `jaeger` container, learn more from the [Kubernetes documentation](https://kubernetes.io/docs/tasks/configure-pod-container/security-context/#set-the-security-context-for-a-container) |
167170
| jaeger.enabled | bool | `false` | Enable `jaeger` |
168171
| jaeger.image.defaultTag | string | `"6.0.0@sha256:79548aa11d7e2e6bf3e2012fb9e046df12ba5c5410bc24ec8f4d7cbb880336b9"` | Docker image tag for the `jaeger` image |

charts/sourcegraph/templates/jaeger/jaeger.ConfigMap.yaml

Lines changed: 44 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,5 +10,48 @@ metadata:
1010
name: {{ .Values.jaeger.name }}
1111
data:
1212
jaeger-config.yaml: |
13-
{{- toYaml .Values.jaeger.config | nindent 4 }}
13+
service:
14+
extensions: [jaeger_storage, jaeger_query, remote_sampling, healthcheckv2]
15+
pipelines:
16+
traces:
17+
receivers: [otlp]
18+
processors: [batch]
19+
exporters: [jaeger_storage_exporter]
20+
telemetry:
21+
logs:
22+
level: {{ .Values.jaeger.config.logLevel | default "info" }}
23+
extensions:
24+
healthcheckv2:
25+
use_v2: true
26+
http:
27+
endpoint: "0.0.0.0:13133"
28+
jaeger_storage:
29+
backends:
30+
main_store:
31+
memory:
32+
max_traces: {{ .Values.jaeger.config.maxTraces | default 20000 }}
33+
jaeger_query:
34+
storage:
35+
traces: main_store
36+
base_path: "/-/debug/jaeger"
37+
http:
38+
endpoint: "0.0.0.0:16686"
39+
remote_sampling:
40+
file:
41+
path: /etc/jaeger/sampling_strategies.json
42+
default_sampling_probability: {{ .Values.jaeger.config.samplingDefaultProbability | default 1.0 }}
43+
http:
44+
endpoint: "0.0.0.0:5778"
45+
receivers:
46+
otlp:
47+
protocols:
48+
grpc:
49+
endpoint: "0.0.0.0:4317"
50+
http:
51+
endpoint: "0.0.0.0:4318"
52+
processors:
53+
batch: {}
54+
exporters:
55+
jaeger_storage_exporter:
56+
trace_storage: main_store
1457
{{- end }}

charts/sourcegraph/templates/jaeger/jaeger.Deployment.yaml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -30,7 +30,7 @@ spec:
3030
kubectl.kubernetes.io/default-container: jaeger
3131
prometheus.io/port: "16686"
3232
sourcegraph.prometheus/scrape: "true"
33-
checksum/jaeger-config: {{ toYaml .Values.jaeger.config | sha256sum }}
33+
checksum/jaeger-config: {{ include (print $.Template.BasePath "/jaeger/jaeger.ConfigMap.yaml") . | sha256sum }}
3434
{{- if .Values.sourcegraph.podAnnotations }}
3535
{{- toYaml .Values.sourcegraph.podAnnotations | nindent 8 }}
3636
{{- end }}

charts/sourcegraph/values.yaml

Lines changed: 8 additions & 47 deletions
Original file line numberDiff line numberDiff line change
@@ -1183,55 +1183,16 @@ jaeger:
11831183
[
11841184
"--config=/etc/jaeger/jaeger-config.yaml",
11851185
]
1186-
# -- Jaeger v2 YAML configuration. This is rendered into a ConfigMap and
1187-
# mounted at `/etc/jaeger/jaeger-config.yaml`. Customers can override
1188-
# individual settings (e.g., `max_traces`, sampling) directly in values.yaml.
1186+
# -- Jaeger v2 configuration overrides. These values are templated into
1187+
# a ConfigMap mounted at `/etc/jaeger/jaeger-config.yaml`.
11891188
# See https://www.jaegertracing.io/docs/2.16/configuration/
11901189
config:
1191-
service:
1192-
extensions: [jaeger_storage, jaeger_query, remote_sampling, healthcheckv2]
1193-
pipelines:
1194-
traces:
1195-
receivers: [otlp]
1196-
processors: [batch]
1197-
exporters: [jaeger_storage_exporter]
1198-
telemetry:
1199-
logs:
1200-
level: info
1201-
extensions:
1202-
healthcheckv2:
1203-
use_v2: true
1204-
http:
1205-
endpoint: "0.0.0.0:13133"
1206-
jaeger_storage:
1207-
backends:
1208-
main_store:
1209-
memory:
1210-
max_traces: 20000
1211-
jaeger_query:
1212-
storage:
1213-
traces: main_store
1214-
base_path: "/-/debug/jaeger"
1215-
http:
1216-
endpoint: "0.0.0.0:16686"
1217-
remote_sampling:
1218-
file:
1219-
path: /etc/jaeger/sampling_strategies.json
1220-
default_sampling_probability: 1.0
1221-
http:
1222-
endpoint: "0.0.0.0:5778"
1223-
receivers:
1224-
otlp:
1225-
protocols:
1226-
grpc:
1227-
endpoint: "0.0.0.0:4317"
1228-
http:
1229-
endpoint: "0.0.0.0:4318"
1230-
processors:
1231-
batch: {}
1232-
exporters:
1233-
jaeger_storage_exporter:
1234-
trace_storage: main_store
1190+
# -- Maximum number of traces stored in memory
1191+
maxTraces: 20000
1192+
# -- Log level for the Jaeger instance (debug, info, warn, error)
1193+
logLevel: info
1194+
# -- Default sampling probability (0.0 to 1.0) returned to services that query Jaeger for sampling config
1195+
samplingDefaultProbability: 1.0
12351196
# -- Security context for the `jaeger` container,
12361197
# learn more from the [Kubernetes documentation](https://kubernetes.io/docs/tasks/configure-pod-container/security-context/#set-the-security-context-for-a-container)
12371198
containerSecurityContext:

0 commit comments

Comments
 (0)