diff options
author | Krzysztof Opasiak <k.opasiak@samsung.com> | 2021-05-06 22:18:45 +0000 |
---|---|---|
committer | Gerrit Code Review <gerrit@onap.org> | 2021-05-06 22:18:45 +0000 |
commit | 48d51d0cc0f93f60bf94722745c8be75372a4bdd (patch) | |
tree | b26c5a4680eb8d7e221bda6ccf1e27cf744fac76 | |
parent | 1f37bd8757c389d15b1d5c6fe491c57e854df1f7 (diff) | |
parent | e7616c3ea9d805edf625c9eac622f97d1e648d5a (diff) |
Merge "[COMMON][CASSANDRA] Use Startup probes"
-rw-r--r-- | kubernetes/common/cassandra/templates/statefulset.yaml | 11 | ||||
-rw-r--r-- | kubernetes/common/cassandra/values.yaml | 15 |
2 files changed, 22 insertions, 4 deletions
diff --git a/kubernetes/common/cassandra/templates/statefulset.yaml b/kubernetes/common/cassandra/templates/statefulset.yaml index 953c89d24d..3553cd4069 100644 --- a/kubernetes/common/cassandra/templates/statefulset.yaml +++ b/kubernetes/common/cassandra/templates/statefulset.yaml @@ -71,6 +71,17 @@ spec: timeoutSeconds: {{ .Values.readiness.timeoutSeconds }} successThreshold: {{ .Values.readiness.successThreshold }} failureThreshold: {{ .Values.readiness.failureThreshold }} + startupProbe: + exec: + command: + - /bin/bash + - -c + - nodetool status | grep $POD_IP | awk '$1!="UN" { exit 1; }' + initialDelaySeconds: {{ .Values.startup.initialDelaySeconds }} + periodSeconds: {{ .Values.startup.periodSeconds }} + timeoutSeconds: {{ .Values.startup.timeoutSeconds }} + successThreshold: {{ .Values.startup.successThreshold }} + failureThreshold: {{ .Values.startup.failureThreshold }} env: {{- $seed_size := default 1 .Values.replicaCount | int -}} {{- $global := . }} diff --git a/kubernetes/common/cassandra/values.yaml b/kubernetes/common/cassandra/values.yaml index c3d22cedc0..5a50d8e9e8 100644 --- a/kubernetes/common/cassandra/values.yaml +++ b/kubernetes/common/cassandra/values.yaml @@ -54,8 +54,8 @@ affinity: {} # probe configuration parameters liveness: - initialDelaySeconds: 60 - periodSeconds: 20 + initialDelaySeconds: 1 + periodSeconds: 10 timeoutSeconds: 10 successThreshold: 1 failureThreshold: 3 @@ -64,12 +64,19 @@ liveness: enabled: true readiness: - initialDelaySeconds: 120 - periodSeconds: 20 + initialDelaySeconds: 1 + periodSeconds: 10 timeoutSeconds: 10 successThreshold: 1 failureThreshold: 3 +startup: + initialDelaySeconds: 10 + periodSeconds: 10 + timeoutSeconds: 10 + successThreshold: 1 + failureThreshold: 90 + service: name: cassandra headless: |