From 95eb8a44f585981821b9f53b2a257233866bf4f9 Mon Sep 17 00:00:00 2001 From: Fiete Ostkamp Date: Mon, 24 Feb 2025 16:39:18 +0100 Subject: [SO] Leverage startup probe to avoid initialDelaySeconds of 10 minutes for k8s probes - use startup probe to make so services available as early as possible - define revisionHistoryLimit - reduce default liveness period from 60 seconds to 20 seconds Issue-ID: SO-4144 Change-Id: Ibd84fe1ef2d5c7f55e580fb7cc7b0a4bedff0045 Signed-off-by: Fiete Ostkamp --- .../so/components/so-request-db-adapter/templates/deployment.yaml | 4 +++- kubernetes/so/components/so-request-db-adapter/values.yaml | 4 ++-- 2 files changed, 5 insertions(+), 3 deletions(-) (limited to 'kubernetes/so/components/so-request-db-adapter') diff --git a/kubernetes/so/components/so-request-db-adapter/templates/deployment.yaml b/kubernetes/so/components/so-request-db-adapter/templates/deployment.yaml index 329d45e480..93eef57795 100755 --- a/kubernetes/so/components/so-request-db-adapter/templates/deployment.yaml +++ b/kubernetes/so/components/so-request-db-adapter/templates/deployment.yaml @@ -19,6 +19,7 @@ metadata: {{- include "common.resourceMetadata" . | nindent 2 }} spec: selector: {{- include "common.selectors" . | nindent 4 }} replicas: {{ index .Values.replicaCount }} + revisionHistoryLimit: {{ .Values.revisionHistoryLimit }} minReadySeconds: {{ index .Values.minReadySeconds }} strategy: type: {{ index .Values.updateStrategy.type }} @@ -57,7 +58,8 @@ spec: - name: config mountPath: /app/config readOnly: true -{{ include "so.helpers.livenessProbe" .| indent 8 }} + {{- include "so.helpers.startupProbe" .| indent 8 }} + {{- include "so.helpers.livenessProbe" .| indent 8 }} ports: {{- include "common.containerPorts" . | nindent 10 }} serviceAccountName: {{ include "common.fullname" (dict "suffix" "read" "dot" . )}} volumes: diff --git a/kubernetes/so/components/so-request-db-adapter/values.yaml b/kubernetes/so/components/so-request-db-adapter/values.yaml index 0e12f5150f..d6cad0744b 100755 --- a/kubernetes/so/components/so-request-db-adapter/values.yaml +++ b/kubernetes/so/components/so-request-db-adapter/values.yaml @@ -80,6 +80,7 @@ mso: auth: Basic YnBlbDpwYXNzd29yZDEk replicaCount: 1 +revisionHistoryLimit: 1 minReadySeconds: 10 containerPort: &containerPort 8083 logPath: ./logs/reqdb/ @@ -123,8 +124,7 @@ livenessProbe: path: /manage/health port: 8083 scheme: HTTP - initialDelaySeconds: 600 - periodSeconds: 60 + periodSeconds: 20 timeoutSeconds: 10 successThreshold: 1 failureThreshold: 3 -- cgit