From bee43bf7755341d8a18603fbfe4d86c453aedf55 Mon Sep 17 00:00:00 2001 From: David Montoya Date: Mon, 23 Mar 2026 16:18:21 -0500 Subject: [PATCH] feat: allow setting priority class kubernetes priority classes control pod scheduling order and preemption during resource pressure. for pgdog, which may sit in the critical path of every database connection from applications, being preempted or starved of resources has immediate user-facing impact. --- templates/deployment.yaml | 3 +++ values.yaml | 4 ++++ 2 files changed, 7 insertions(+) diff --git a/templates/deployment.yaml b/templates/deployment.yaml index b63e967..45bbeef 100644 --- a/templates/deployment.yaml +++ b/templates/deployment.yaml @@ -43,6 +43,9 @@ spec: {{- if .Values.serviceAccount.create }} serviceAccountName: {{ include "pgdog.serviceAccountName" . }} {{- end }} + {{- if .Values.priorityClassName }} + priorityClassName: {{ .Values.priorityClassName }} + {{- end }} {{- if .Values.terminationGracePeriodSeconds }} terminationGracePeriodSeconds: {{ .Values.terminationGracePeriodSeconds }} {{- end }} diff --git a/values.yaml b/values.yaml index 881dc75..7d33c5e 100644 --- a/values.yaml +++ b/values.yaml @@ -51,6 +51,10 @@ port: 6432 # replicas indicates how many instances of PgDog will run (HA). replicas: 2 +# priorityClassName assigns a PriorityClass to pgdog pods for scheduling priority. +# Not set by default; omitted from the pod spec unless explicitly specified. +# Example: priorityClassName: production-critical + # Uncomment to enable explicit grace period # terminationGracePeriodSeconds: 90