Skip to content

Commit e758a86

Browse files
authored
Revert version (#84)
* Change PG version back to 14 PG 15 wouldn't work with PGO 5.2, which is our lowest tested version. Issue: PGO-649 * Add note to enum re: patroni * Add comment to enum for pgbackrest
1 parent 94f6057 commit e758a86

File tree

12 files changed

+18
-11
lines changed

12 files changed

+18
-11
lines changed

internal/util/enum.go

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -24,6 +24,9 @@ import "errors"
2424

2525
// 'patroni list' output format options
2626
// - https://patroni.readthedocs.io/en/latest/patronictl.html#patronictl-list
27+
// Note: Patroni has been updated to restrict the input of `--format`,
28+
// so we can remove this when our lowest supported version of Patroni has this fix.
29+
// - https://github.com/zalando/patroni/commit/8adddb3467f3c43ddf4ff723a2381e0cf6e2a31b
2730
type patroniFormat string
2831

2932
const (
@@ -56,6 +59,10 @@ func (e *patroniFormat) Type() string {
5659

5760
// 'pgbackrest info' output format options
5861
// - https://pgbackrest.org/command.html#command-info
62+
// `pgbackrest info` does return an error if the output is not an accepted format
63+
// but without this enum, that error is unclear:
64+
// Without this enum code: `Error: command terminated with exit code 32`
65+
// With this enum code: `Error: invalid argument "jsob" for "-o, --output" flag: must be one of "text", "json"`
5966
type pgbackrestFormat string
6067

6168
const (

testing/kuttl/e2e/backup/00--cluster.yaml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@ kind: PostgresCluster
33
metadata:
44
name: backup-cluster
55
spec:
6-
postgresVersion: 15
6+
postgresVersion: 14
77
instances:
88
- name: instance1
99
dataVolumeClaimSpec:

testing/kuttl/e2e/create/00--create_cluster.yaml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,4 +2,4 @@
22
apiVersion: kuttl.dev/v1beta1
33
kind: TestStep
44
commands:
5-
- script: kubectl-pgo --namespace $NAMESPACE create postgrescluster --pg-major-version 15 kuttl-create-cluster
5+
- script: kubectl-pgo --namespace $NAMESPACE create postgrescluster --pg-major-version 14 kuttl-create-cluster

testing/kuttl/e2e/create/00-assert.yaml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,7 @@ spec:
2222
requests:
2323
storage: 1Gi
2424
replicas: 1
25-
postgresVersion: 15
25+
postgresVersion: 14
2626
status:
2727
instances:
2828
- name: "00"

testing/kuttl/e2e/create/01--check_version_validation.yaml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,7 @@ commands:
1818
fi
1919
2020
# Verify the error when the Postgres version is not an integer.
21-
NOT_INT=$(kubectl-pgo create postgrescluster --pg-major-version=15.1 notint 2>&1)
21+
NOT_INT=$(kubectl-pgo create postgrescluster --pg-major-version=14.1 notint 2>&1)
2222
if [[ "${NOT_INT}" != "Error: invalid argument"* ]]; then
2323
printf 'Expected invalid argument error, got %q\n' "${NOT_INT}"
2424
exit 1

testing/kuttl/e2e/delete-cluster/00--cluster.yaml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@ kind: PostgresCluster
33
metadata:
44
name: delete-cluster
55
spec:
6-
postgresVersion: 15
6+
postgresVersion: 14
77
instances:
88
- name: instance1
99
dataVolumeClaimSpec:

testing/kuttl/e2e/restore/00--cluster.yaml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@ kind: PostgresCluster
44
metadata:
55
name: restore-cluster
66
spec:
7-
postgresVersion: 15
7+
postgresVersion: 14
88
instances:
99
- name: instance1
1010
dataVolumeClaimSpec:

testing/kuttl/e2e/show/00--cluster.yaml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@ kind: PostgresCluster
33
metadata:
44
name: show-cluster
55
spec:
6-
postgresVersion: 15
6+
postgresVersion: 14
77
instances:
88
- name: instance1
99
dataVolumeClaimSpec:

testing/kuttl/e2e/support-export/00--create_cluster.yaml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,4 +2,4 @@
22
apiVersion: kuttl.dev/v1beta1
33
kind: TestStep
44
commands:
5-
- script: kubectl-pgo --namespace $NAMESPACE create postgrescluster --pg-major-version 15 kuttl-support-cluster
5+
- script: kubectl-pgo --namespace $NAMESPACE create postgrescluster --pg-major-version 14 kuttl-support-cluster

testing/kuttl/e2e/support-export/00-assert.yaml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,7 @@ spec:
2222
requests:
2323
storage: 1Gi
2424
replicas: 1
25-
postgresVersion: 15
25+
postgresVersion: 14
2626
status:
2727
instances:
2828
- name: "00"

0 commit comments

Comments
 (0)