Skip to content

Commit

Permalink
feat(thanos): Added support for disabling compact dedupe
Browse files Browse the repository at this point in the history
Signed-off-by: Steve Hipwell <[email protected]>
  • Loading branch information
stevehipwell committed Dec 4, 2023
1 parent bf08f63 commit f657d58
Show file tree
Hide file tree
Showing 5 changed files with 24 additions and 2 deletions.
9 changes: 9 additions & 0 deletions charts/thanos/CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -20,11 +20,20 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0

## [UNRELEASED]

### Added

- Added `compact.deduplication.enabled` value to disable compact deduplication.
- Added `compact.deduplication.func` value to set the compact deduplication function.

### Changed

- Changed the default `configmap-reload` image variant to `cgr.dev/chainguard/configmap-reload:latest`.
- Added support for specifying custom Kubernetes cluster domain

### Deprecated

- Deprecated the `compact.replicaDeduplication` value in favour of setting `compact.deduplication.func=penalty`.

## [v1.14.5] - 2023-10-20

### Changed
Expand Down
3 changes: 3 additions & 0 deletions charts/thanos/ci/ci-values.yaml
Original file line number Diff line number Diff line change
@@ -1,6 +1,9 @@
compact:
enabled: false

deduplication:
enabled: false

queryFrontend:
enabled: true

Expand Down
4 changes: 3 additions & 1 deletion charts/thanos/ci/kubeconform.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,9 @@ compact:
persistence:
enabled: true

replicaDeduplication: true
deduplication:
enabled: true
func: penalty

nodeSelector:
kubernetes.io/os: linux
Expand Down
6 changes: 5 additions & 1 deletion charts/thanos/templates/compact/statefulset.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -76,12 +76,16 @@ spec:
- --http-address=0.0.0.0:10902
- --data-dir=/var/thanos/compact
- --objstore.config-file=/etc/thanos/objstore.yaml
{{- if .Values.compact.deduplication.enabled }}
{{- range (concat .Values.additionalReplicaLabels (ternary (list "rule_replica") (list) .Values.rule.enabled ) (ternary (list "receive_replica") (list) .Values.receive.enabled )) | uniq }}
- --deduplication.replica-label={{ . }}
{{- end }}
{{- if .Values.compact.replicaDeduplication }}
{{- if .Values.compact.deduplication.func }}
- --deduplication.func={{ .Values.compact.deduplication.func }}
{{- else if .Values.compact.replicaDeduplication }}
- --deduplication.func=penalty
{{- end }}
{{- end }}
{{- with .Values.compact.extraArgs }}
{{- toYaml . | nindent 12 }}
{{- end }}
Expand Down
4 changes: 4 additions & 0 deletions charts/thanos/values.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -70,6 +70,10 @@ compact:

extraEnv: []

deduplication:
enabled: true
func:

replicaDeduplication: false

extraArgs: []
Expand Down

0 comments on commit f657d58

Please sign in to comment.