diff --git a/Chart.yaml b/Chart.yaml index 867cfee..fa9e103 100644 --- a/Chart.yaml +++ b/Chart.yaml @@ -2,5 +2,5 @@ apiVersion: v2 name: pgdog-control description: PgDog Control type: application -version: 0.3.1 +version: 0.3.2 appVersion: "f477677f" diff --git a/README.md b/README.md index 1f169b4..6766c4e 100644 --- a/README.md +++ b/README.md @@ -709,6 +709,7 @@ control: cpu: 90.0 memory: 2048 server_connections: 100 + checkout_timeouts: 1 slow_queries: true incident_io: api_key: inc_live_xxx @@ -721,6 +722,7 @@ control: | `thresholds.cpu` | CPU usage percentage. Must be between `0.0` and `100.0`, inclusive (float, optional). | | `thresholds.memory` | Memory used, in megabytes (int, optional). | | `thresholds.server_connections` | Number of open server connections (int, optional). | +| `thresholds.checkout_timeouts` | Checkout timeouts per second, averaged over the evaluation window and summed across running instances (int, optional). | | `thresholds.slow_queries` | Create incidents for queries whose duration reaches `store.slow_queries_threshold` (bool, default `false`). | | `incident_io.api_key` | incident.io API key with permission to create incidents. Missing `incident_io` disables the integration (string, optional). | diff --git a/templates/configmap.yaml b/templates/configmap.yaml index 5735864..276c5e4 100644 --- a/templates/configmap.yaml +++ b/templates/configmap.yaml @@ -212,6 +212,9 @@ data: {{- if hasKey . "server_connections" }} server_connections = {{ .server_connections }} {{- end }} + {{- if hasKey . "checkout_timeouts" }} + checkout_timeouts = {{ .checkout_timeouts }} + {{- end }} {{- if hasKey . "slow_queries" }} slow_queries = {{ .slow_queries }} {{- end }} diff --git a/test/test.sh b/test/test.sh index d8c3ebe..59b8a8a 100755 --- a/test/test.sh +++ b/test/test.sh @@ -20,6 +20,7 @@ full_render=$(helm template test-release "$CHART_DIR" -f "$TEST_DIR/values-full. grep -q '^ query_plans_limit = 75$' <<< "$full_render" grep -q '^ slow_queries_threshold = 2500$' <<< "$full_render" grep -q '^ slow_queries = true$' <<< "$full_render" +grep -q '^ checkout_timeouts = 1$' <<< "$full_render" echo "" echo "==> Verifying external Redis rendering..." diff --git a/test/values-full.yaml b/test/values-full.yaml index 1928a64..68da0ee 100644 --- a/test/values-full.yaml +++ b/test/values-full.yaml @@ -65,6 +65,7 @@ control: cpu: 90.0 memory: 2048 server_connections: 100 + checkout_timeouts: 1 slow_queries: true incident_io: api_key: incident-token diff --git a/values.yaml b/values.yaml index 4c4e7d2..4a9e1c7 100644 --- a/values.yaml +++ b/values.yaml @@ -173,6 +173,7 @@ control: # cpu: 90.0 # memory: 2048 # server_connections: 100 + # checkout_timeouts: 1 # Timeouts/sec, averaged over the evaluation window across running instances. # slow_queries: false # incident_io: # api_key: ""