Skip to content

Commit cfabdfe

Browse files
committed
Remove elasticsearch and cassandra deps. Clean up unused helpers. Simplify.
Signed-off-by: Steven Erb <stevenpc3@live.com>
1 parent d1f96dc commit cfabdfe

19 files changed

Lines changed: 61 additions & 489 deletions

Makefile

Lines changed: 0 additions & 19 deletions
Original file line numberDiff line numberDiff line change
@@ -8,22 +8,3 @@ lint:
88
.PHONY: test
99
test:
1010
ct install --config ct.yaml
11-
12-
# This test will spin up the local provisioned elasticsearch and then connect jaeger to it not using memory store
13-
# it disables the built-in elasticsearch test since it just checks if it's up and jaeger connecting does the same
14-
# elasticsearch test also requires ssl and jaeger is configured to not require that for local connection
15-
.PHONY: test-jaeger-connect-elasticsearch
16-
test-jaeger-connect-elasticsearch:
17-
ct install --config ct.yaml \
18-
--charts charts/jaeger \
19-
--helm-extra-set-args " \
20-
--set provisionDataStore.elasticsearch=true \
21-
--set storage.type=elasticsearch \
22-
--set elasticsearch.tests.enabled=false \
23-
--set elasticsearch.readinessProbe.initialDelaySeconds=60 \
24-
--set elasticsearch.readinessProbe.failureThreshold=10 \
25-
--set elasticsearch.volumeClaimTemplate.resources.requests.storage=5Gi \
26-
--set elasticsearch.protocol=http \
27-
--set config.extensions.jaeger_query.storage.traces=primary_store_elasticsearch \
28-
--set config.extensions.jaeger_query.storage.traces_archive=archive_store_elasticsearch \
29-
--set config.exporters.jaeger_storage_exporter.trace_storage=primary_store_elasticsearch "

charts/jaeger/Chart.yaml

Lines changed: 0 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -27,14 +27,6 @@ maintainers:
2727
- name: jkowall
2828
email: jkowall@kowall.net
2929
dependencies:
30-
- name: cassandra
31-
version: 0.15.3
32-
repository: https://charts.helm.sh/incubator
33-
condition: provisionDataStore.cassandra
34-
- name: elasticsearch
35-
version: 8.5.1
36-
repository: https://helm.elastic.co
37-
condition: provisionDataStore.elasticsearch
3830
- name: common
3931
repository: https://charts.bitnami.com/bitnami
4032
version: 2.x.x

charts/jaeger/README.md

Lines changed: 32 additions & 30 deletions
Original file line numberDiff line numberDiff line change
@@ -12,15 +12,18 @@ This release is a refactor designed to simplify operation and configuration.
1212
- **Configuration**: Storage is configured via the `config.extensions.jaeger_storage` section using native Jaeger/OTEL config syntax.
1313
- **Cassandra Schema**: Jaeger v2 handles schema creation internally. The legacy schema job has been removed.
1414
- **Service Consolidation**: A single Service now exposes all ports (agent, collector, query).
15+
- **No provisioned storage**: Dependency charts have been removed. The user must deploy them separately and configure connection using the Otel config Syntax https://github.com/jaegertracing/jaeger/blob/main/cmd/jaeger/config.yaml
1516

1617
## Architecture
1718

1819
This chart uses the **All-In-One** deployment model.
1920
- **Single Binary**: Runs as a `Deployment` scalable to multiple replicas.
2021
- **Stateless**: Can connect to external persistent storage (Elasticsearch, Cassandra) for production use.
2122
- **Default**: Memory storage (ephemeral), suitable for testing.
23+
- **Scalable**: Increase replica count to scale horizontally
2224

23-
## Overriding the Jaeger Version
25+
## Overriding the Jaeger Version
26+
##### (chart only supports Jaever v2+)
2427

2528
You can customize the Jaeger image and tag using the following values:
2629

@@ -61,37 +64,16 @@ helm install jaeger jaegertracing/jaeger
6164
```
6265

6366
### 2. Elasticsearch (Production Recommended)
64-
Configure Jaeger to connect to Elasticsearch using the native config syntax.
6567

66-
You can either use the internal provisioned elasticsearch or point to an external elasticsearch.
68+
This chart does not provision an ElasticSearch instance.
6769

68-
The internal elasticsearch is configured to __NOT__ require a password or username by default.
70+
To use ElasticSearch storage, you must provide your own ElasticSearch instance and configure Jaeger via the native config syntax:
6971

70-
#### Internal Provisioned Elasticsearch example:
72+
#### Elasticsearch example:
7173

7274
**values.yaml**
7375
```yaml
74-
# Use the provisioned Elasticsearch subchart
75-
provisionDataStore:
76-
elasticsearch: true
77-
78-
config:
79-
extensions:
80-
jaeger_query:
81-
storage:
82-
traces: primary_store_elasticsearch
83-
traces_archive: archive_store_elasticsearch
84-
exporters:
85-
jaeger_storage_exporter:
86-
trace_storage: primary_store_elasticsearch
87-
```
88-
89-
#### External Elasticsearch example:
90-
91-
**values.yaml**
92-
```yaml
93-
# External is very similar but you need to configure the urls
94-
config:
76+
userconfig:
9577
extensions:
9678
jaeger_query:
9779
storage:
@@ -119,17 +101,29 @@ config:
119101
```
120102
121103
**Running Maintenance Jobs:**
122-
To run Index Cleaner or Rollover jobs, enable them. They require configuration if using external by setting ```storage.type=elasticsearch``` and adjusting ```storage.elasticsearch``` values. See that section in values.yaml for more details.
104+
105+
To run Index Cleaner or Rollover jobs, enable them.
106+
They require configuration by adjusting ```storage.elasticsearch``` values. See that section in values.yaml for more details.
123107

124108
```yaml
125109
esIndexCleaner:
126110
enabled: true
111+
112+
storage:
113+
elasticsearch:
114+
tls:
115+
enabled: false
116+
url: http://elasticsearch-master:9200
117+
# user: elastic
118+
# password: changeme
127119
```
128120

129121
* es-rollover __requires__ elasticsearch to be running __BEFORE__ install so the hook job can run.
130122

131123
### 3. Cassandra
132-
This chart does not provision a Cassandra cluster. To use Cassandra storage, you must provide your own Cassandra instance and configure Jaeger via the native config syntax:
124+
This chart does not provision a Cassandra cluster.
125+
126+
To use Cassandra storage, you must provide your own Cassandra instance and configure Jaeger via the native config syntax:
133127

134128
**values.yaml Example:**
135129
```yaml
@@ -158,7 +152,9 @@ To run the Spark dependencies job (for dependency links graph) set ```spark.enab
158152

159153
Below is an example of how to set overrides. Please see the values.yaml for more examples:
160154

161-
The values are populated under ```storage.elasticsearch``` Please see comments in values.yaml for more details.
155+
The values are populated under ```storage.elasticsearch``` and ```storage.casandra``` Please see comments in values.yaml for more details.
156+
157+
You must choose the storage type with ```storage.type=elasticsearch``` or ```storage.type=cassandra```
162158

163159
```yaml
164160
spark:
@@ -172,7 +168,11 @@ For a full list of supported environment variables, see the [Spark Dependencies
172168

173169
### 5. Query UI
174170

175-
To enable the query ui, you need to enable the ingress and fill at least one host:
171+
To access the ui you can either:
172+
173+
* enable the ingress and fill at least one host
174+
* provide your own ingress
175+
* or port forward ```kubectl port-forward --namespace {{ .Release.Namespace }} $POD_NAME 16686:16686 --address 0.0.0.0``` and access at http://localhost:16686/
176176

177177
```yaml
178178
jaeger:
@@ -182,6 +182,8 @@ jaeger:
182182
- <fill a host here>
183183
```
184184

185+
You can customize the UI by setting ```uiconfig```. Please see the values.yaml for examples or https://github.com/jaegertracing/jaeger/tree/main/cmd/jaeger
186+
185187
## Configuring the Collector
186188

187189
The Jaeger v2 configuration is defined in `config` using OpenTelemetry Collector syntax. You can override pipelines, receivers, and processors there.

charts/jaeger/templates/NOTES.txt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -17,6 +17,6 @@ To access the query UI:
1717
{{- end }}
1818
{{- else }}
1919
export POD_NAME=$(kubectl get pods --namespace {{ .Release.Namespace }} -l "app.kubernetes.io/instance={{ .Release.Name }},app.kubernetes.io/component=all-in-one" -o jsonpath="{.items[0].metadata.name}")
20-
echo "Visit http://127.0.0.1:16686/"
2120
kubectl port-forward --namespace {{ .Release.Namespace }} $POD_NAME 16686:16686
21+
Visit http://127.0.0.1:16686/
2222
{{- end }}

charts/jaeger/templates/_helpers.tpl

Lines changed: 5 additions & 158 deletions
Original file line numberDiff line numberDiff line change
@@ -95,13 +95,7 @@ Create the name of the esLookback service account to use
9595
{{- end -}}
9696
{{- end -}}
9797

98-
99-
100-
101-
102-
10398
{{- define "cassandra.host" -}}
104-
{{- if .Values.provisionDataStore.cassandra -}}
10599
{{- if .Values.storage.cassandra.nameOverride }}
106100
{{- printf "%s" .Values.storage.cassandra.nameOverride | trunc 63 | trimSuffix "-" }}
107101
{{- else }}
@@ -114,7 +108,6 @@ Create the name of the esLookback service account to use
114108

115109
{{- define "cassandra.contact_points" -}}
116110
{{- $port := .Values.storage.cassandra.port | toString }}
117-
{{- if .Values.provisionDataStore.cassandra -}}
118111
{{- if .Values.storage.cassandra.nameOverride }}
119112
{{- $host := printf "%s" .Values.storage.cassandra.nameOverride | trunc 63 | trimSuffix "-" -}}
120113
{{- printf "%s:%s" $host $port }}
@@ -149,6 +142,7 @@ Configure list of IP CIDRs allowed access to load balancer (if supported)
149142

150143
{{/*
151144
Cassandra related environment variables
145+
TODO: Is this needed other than spark?
152146
*/}}
153147
{{- define "cassandra.env" -}}
154148
- name: CASSANDRA_SERVERS
@@ -190,48 +184,11 @@ Cassandra related environment variables
190184
{{- end }}
191185
{{- end -}}
192186

193-
194-
{{/*
195-
grpcPlugin related environment variables
196-
*/}}
197-
{{- define "grpcPlugin.env" -}}
198-
{{- if .Values.storage.grpcPlugin.extraEnv }}
199-
{{- toYaml .Values.storage.grpcPlugin.extraEnv }}
200-
{{- end }}
201-
{{- end -}}
202-
203-
{{/*
204-
badger related environment variables
205-
*/}}
206-
{{- define "badger.env" -}}
207-
- name: BADGER_EPHEMERAL
208-
value: {{ .Values.storage.badger.ephemeral | quote }}
209-
{{- if not .Values.storage.badger.ephemeral }}
210-
- name: BADGER_DIRECTORY_VALUE
211-
value: {{ print .Values.storage.badger.persistence.mountPath "/badger/data" | quote }}
212-
- name: BADGER_DIRECTORY_KEY
213-
value: {{ print .Values.storage.badger.persistence.mountPath "/badger/key" | quote }}
214-
{{- end }}
215-
{{- if .Values.storage.badger.extraEnv }}
216-
{{- toYaml .Values.storage.badger.extraEnv }}
217-
{{- end }}
218-
{{- end -}}
219-
220-
{{/*
221-
memory related environment variables
222-
*/}}
223-
{{- define "memory.env" -}}
224-
{{- if .Values.storage.memory.extraEnv }}
225-
{{- toYaml .Values.storage.memory.extraEnv }}
226-
{{- end }}
227-
{{- end -}}
228-
229-
230187
{{/*
231188
Elasticsearch related environment variables
232189
*/}}
233190
{{- define "elasticsearch.env" -}}
234-
{{- if or .Values.provisionDataStore.elasticsearch (eq .Values.storage.type "elasticsearch") -}}
191+
{{- if eq .Values.storage.type "elasticsearch" -}}
235192
{{- $es := .Values.storage.elasticsearch | default dict -}}
236193
{{- $user := $es.user | default "elastic" -}}
237194
{{- $password := $es.password | default "changeme" -}}
@@ -253,116 +210,15 @@ Elasticsearch related environment variables
253210
{{- end -}}
254211

255212
{{/*
256-
Cassandra, Elasticsearch, or grpc-plugin, badger, memory related environment variables depending on which is used
213+
Cassandra, Elasticsearch related environment variables depending on which is used
214+
TODO: storage.env only used in spark
257215
*/}}
258216
{{- define "storage.env" -}}
259217
{{- if eq .Values.storage.type "cassandra" -}}
260218
{{ include "cassandra.env" . }}
261-
{{- else if or (eq .Values.storage.type "elasticsearch") .Values.provisionDataStore.elasticsearch -}}
262-
{{ include "elasticsearch.env" . }}
263-
{{- else if or (eq .Values.storage.type "grpc-plugin") (eq .Values.storage.type "grpc") -}}
264-
{{ include "grpcPlugin.env" . }}
265-
{{- else if eq .Values.storage.type "badger" -}}
266-
{{ include "badger.env" . }}
267-
{{- else if eq .Values.storage.type "memory" -}}
268-
{{ include "memory.env" . }}
269-
{{- end -}}
270-
{{- end -}}
271-
272-
{{/*
273-
Cassandra related command line options
274-
*/}}
275-
{{- define "cassandra.cmdArgs" -}}
276-
{{- range $key, $value := .Values.storage.cassandra.cmdlineParams -}}
277-
{{- if $value }}
278-
- --{{ $key }}={{ $value }}
279-
{{- else }}
280-
- --{{ $key }}
281-
{{- end -}}
282-
{{- end -}}
283-
{{- end -}}
284-
285-
286-
{{/*
287-
Cassandra or Elasticsearch related command line options depending on which is used
288-
*/}}
289-
{{- define "storage.cmdArgs" -}}
290-
{{- if eq .Values.storage.type "cassandra" -}}
291-
{{- include "cassandra.cmdArgs" . -}}
292219
{{- else if eq .Values.storage.type "elasticsearch" -}}
293-
# No specific helper, usage depends on args
294-
{{- end -}}
295-
{{- end -}}
296-
297-
298-
{{/*
299-
Provides a basic ingress network policy
300-
*/}}
301-
{{- define "jaeger.ingress.networkPolicy" -}}
302-
apiVersion: {{ include "common.capabilities.networkPolicy.apiVersion" . }}
303-
kind: NetworkPolicy
304-
metadata:
305-
name: {{ printf "%s-ingress" .Name }}
306-
namespace: {{ .Release.Namespace }}
307-
labels:
308-
app.kubernetes.io/component: {{ .Component }}
309-
{{- include "jaeger.labels" . | nindent 4 }}
310-
spec:
311-
podSelector:
312-
matchLabels:
313-
app.kubernetes.io/component: {{ .Component }}
314-
policyTypes:
315-
- Ingress
316-
ingress:
317-
{{- if or .ComponentValues.networkPolicy.ingressRules.namespaceSelector .ComponentValues.networkPolicy.ingressRules.podSelector }}
318-
- from:
319-
{{- if .ComponentValues.networkPolicy.ingressRules.namespaceSelector }}
320-
- namespaceSelector:
321-
matchLabels: {{- include "common.tplvalues.render" (dict "value" .ComponentValues.networkPolicy.ingressRules.namespaceSelector "context" $) | nindent 10 }}
322-
{{- end }}
323-
{{- if .ComponentValues.networkPolicy.ingressRules.podSelector }}
324-
- podSelector:
325-
matchLabels: {{- include "common.tplvalues.render" (dict "value" .ComponentValues.networkPolicy.ingressRules.podSelector "context" $) | nindent 10 }}
326-
{{- end }}
327-
{{- end }}
328-
{{- if .ComponentValues.networkPolicy.ingressRules.customRules }}
329-
{{- include "common.tplvalues.render" (dict "value" .ComponentValues.networkPolicy.ingressRules.customRules "context" $) | nindent 2 }}
330-
{{- end }}
220+
{{ include "elasticsearch.env" . }}
331221
{{- end -}}
332-
333-
{{/*
334-
Provides a basic egress network policy
335-
*/}}
336-
{{- define "jaeger.egress.networkPolicy" -}}
337-
apiVersion: {{ include "common.capabilities.networkPolicy.apiVersion" . }}
338-
kind: NetworkPolicy
339-
metadata:
340-
name: {{ printf "%s-egress" .Name }}
341-
namespace: {{ .Release.Namespace }}
342-
labels:
343-
app.kubernetes.io/component: {{ .Component }}
344-
{{- include "jaeger.labels" . | nindent 4 }}
345-
spec:
346-
podSelector:
347-
matchLabels:
348-
app.kubernetes.io/component: {{ .Component }}
349-
policyTypes:
350-
- Egress
351-
egress:
352-
{{- if or .ComponentValues.networkPolicy.egressRules.namespaceSelector .ComponentValues.networkPolicy.egressRules.podSelector }}
353-
- to:
354-
{{- if .ComponentValues.networkPolicy.egressRules.namespaceSelector }}
355-
- namespaceSelector:
356-
matchLabels: {{- include "common.tplvalues.render" (dict "value" .ComponentValues.networkPolicy.egressRules.namespaceSelector "context" $) | nindent 10 }}
357-
{{- end }}
358-
{{- if .ComponentValues.networkPolicy.egressRules.podSelector }}
359-
- podSelector:
360-
matchLabels: {{- include "common.tplvalues.render" (dict "value" .ComponentValues.networkPolicy.egressRules.podSelector "context" $) | nindent 10 }}
361-
{{- end }}
362-
{{- end }}
363-
{{- if .ComponentValues.networkPolicy.egressRules.customRules }}
364-
{{- include "common.tplvalues.render" (dict "value" .ComponentValues.networkPolicy.egressRules.customRules "context" $) | nindent 2 }}
365-
{{- end }}
366222
{{- end -}}
367223

368224
{{/*
@@ -445,15 +301,6 @@ Create pull secrets for esLookback image
445301
{{- include "common.images.renderPullSecrets" (dict "images" (list .Values.esLookback.image) "context" $) -}}
446302
{{- end }}
447303

448-
449-
{{- define "jaeger.namespace" -}}
450-
{{- if .Values.namespaceOverride -}}
451-
{{- .Values.namespaceOverride -}}
452-
{{- else -}}
453-
{{- .Release.Namespace -}}
454-
{{- end -}}
455-
{{- end -}}
456-
457304
{{/*
458305
Generate command line arguments from a dictionary
459306
*/}}

0 commit comments

Comments
 (0)