reflect new pooler parameter in validation + define same pooler image everywhere
This commit is contained in:
parent
2bba673f1d
commit
4d12615c0d
|
|
@ -327,18 +327,21 @@ spec:
|
|||
connection_pool_user:
|
||||
type: string
|
||||
#default: "pooler"
|
||||
connection_pool_number_of_instances:
|
||||
type: integer
|
||||
#default: 1
|
||||
connection_pool_image:
|
||||
type: string
|
||||
#default: "registry.opensource.zalan.do/acid/pgbouncer:1.0.0"
|
||||
#default: "registry.opensource.zalan.do/acid/pgbouncer:master-5"
|
||||
connection_pool_max_db_connections:
|
||||
type: integer
|
||||
#default: 60
|
||||
connection_pool_mode:
|
||||
type: string
|
||||
enum:
|
||||
- "session"
|
||||
- "transaction"
|
||||
#default: "transaction"
|
||||
connection_pool_number_of_instances:
|
||||
type: integer
|
||||
#default: 1
|
||||
connection_pool_default_cpu_limit:
|
||||
type: string
|
||||
pattern: '^(\d+m|\d+(\.\d{1,3})?)$'
|
||||
|
|
|
|||
|
|
@ -111,8 +111,13 @@ spec:
|
|||
properties:
|
||||
dockerImage:
|
||||
type: string
|
||||
maxDBConnections:
|
||||
type: integer
|
||||
mode:
|
||||
type: string
|
||||
enum:
|
||||
- "session"
|
||||
- "transaction"
|
||||
numberOfInstances:
|
||||
type: integer
|
||||
minimum: 1
|
||||
|
|
@ -244,22 +249,6 @@ spec:
|
|||
type: string
|
||||
replicaLoadBalancer: # deprecated
|
||||
type: boolean
|
||||
connectionPool:
|
||||
type: object
|
||||
properties:
|
||||
schema:
|
||||
type: string
|
||||
user:
|
||||
type: string
|
||||
number_of_instances:
|
||||
type: integer
|
||||
dockerImage:
|
||||
type: string
|
||||
mode:
|
||||
type: string
|
||||
enum:
|
||||
- "session"
|
||||
- "transaction"
|
||||
resources:
|
||||
type: object
|
||||
required:
|
||||
|
|
|
|||
|
|
@ -15,7 +15,7 @@ data:
|
|||
# connection_pool_default_cpu_request: "1"
|
||||
# connection_pool_default_memory_limit: 100m
|
||||
# connection_pool_default_memory_request: "100Mi"
|
||||
connection_pool_image: "registry.opensource.zalan.do/acid/pgbouncer:master-3"
|
||||
connection_pool_image: "registry.opensource.zalan.do/acid/pgbouncer:master-5"
|
||||
# connection_pool_number_of_instances: 1
|
||||
# connection_pool_mode: "transaction"
|
||||
# connection_pool_schema: "pooler"
|
||||
|
|
|
|||
|
|
@ -303,18 +303,21 @@ spec:
|
|||
connection_pool_user:
|
||||
type: string
|
||||
#default: "pooler"
|
||||
connection_pool_number_of_instances:
|
||||
type: integer
|
||||
#default: 1
|
||||
connection_pool_image:
|
||||
type: string
|
||||
#default: "registry.opensource.zalan.do/acid/pgbouncer:1.0.0"
|
||||
#default: "registry.opensource.zalan.do/acid/pgbouncer:master-5"
|
||||
connection_pool_max_db_connections:
|
||||
type: integer
|
||||
#default: 60
|
||||
connection_pool_mode:
|
||||
type: string
|
||||
enum:
|
||||
- "session"
|
||||
- "transaction"
|
||||
#default: "transaction"
|
||||
connection_pool_number_of_instances:
|
||||
type: integer
|
||||
#default: 1
|
||||
connection_pool_default_cpu_limit:
|
||||
type: string
|
||||
pattern: '^(\d+m|\d+(\.\d{1,3})?)$'
|
||||
|
|
|
|||
|
|
@ -126,7 +126,7 @@ configuration:
|
|||
connection_pool_default_cpu_request: "1"
|
||||
connection_pool_default_memory_limit: 100m
|
||||
connection_pool_default_memory_request: "100Mi"
|
||||
connection_pool_image: "registry.opensource.zalan.do/acid/pgbouncer:master-3"
|
||||
connection_pool_image: "registry.opensource.zalan.do/acid/pgbouncer:master-5"
|
||||
connection_pool_number_of_instances: 1
|
||||
connection_pool_mode: "transaction"
|
||||
# connection_pool_schema: "pooler"
|
||||
|
|
|
|||
|
|
@ -75,6 +75,8 @@ spec:
|
|||
properties:
|
||||
dockerImage:
|
||||
type: string
|
||||
maxDBConnections:
|
||||
type: integer
|
||||
mode:
|
||||
type: string
|
||||
enum:
|
||||
|
|
|
|||
|
|
@ -182,6 +182,9 @@ var PostgresCRDResourceValidation = apiextv1beta1.CustomResourceValidation{
|
|||
"dockerImage": {
|
||||
Type: "string",
|
||||
},
|
||||
"maxDBConnections": {
|
||||
Type: "integer",
|
||||
},
|
||||
"mode": {
|
||||
Type: "string",
|
||||
Enum: []apiextv1beta1.JSON{
|
||||
|
|
@ -1129,9 +1132,8 @@ var OperatorConfigCRDResourceValidation = apiextv1beta1.CustomResourceValidation
|
|||
"connection_pool_image": {
|
||||
Type: "string",
|
||||
},
|
||||
"connection_pool_replicas": {
|
||||
Type: "integer",
|
||||
Minimum: &min1,
|
||||
"connection_pool_max_db_connections": {
|
||||
Type: "integer",
|
||||
},
|
||||
"connection_pool_mode": {
|
||||
Type: "string",
|
||||
|
|
@ -1144,6 +1146,10 @@ var OperatorConfigCRDResourceValidation = apiextv1beta1.CustomResourceValidation
|
|||
},
|
||||
},
|
||||
},
|
||||
"connection_pool_number_of_instances": {
|
||||
Type: "integer",
|
||||
Minimum: &min1,
|
||||
},
|
||||
"connection_pool_schema": {
|
||||
Type: "string",
|
||||
},
|
||||
|
|
|
|||
|
|
@ -88,13 +88,13 @@ type ConnectionPool struct {
|
|||
NumberOfInstances *int32 `name:"connection_pool_number_of_instances" default:"1"`
|
||||
Schema string `name:"connection_pool_schema" default:"pooler"`
|
||||
User string `name:"connection_pool_user" default:"pooler"`
|
||||
Image string `name:"connection_pool_image" default:"pgbouncer:1.0"`
|
||||
Mode string `name:"connection_pool_mode" default:"session"`
|
||||
Image string `name:"connection_pool_image" default:"registry.opensource.zalan.do/acid/pgbouncer:master-5"`
|
||||
Mode string `name:"connection_pool_mode" default:"transaction"`
|
||||
MaxDBConnections *int32 `name:"connection_pool_max_db_connections" default:"60"`
|
||||
ConnPoolDefaultCPURequest string `name:"connection_pool_default_cpu_request" default:"100m"`
|
||||
ConnPoolDefaultMemoryRequest string `name:"connection_pool_default_memory_request" default:"100Mi"`
|
||||
ConnPoolDefaultCPULimit string `name:"connection_pool_default_cpu_limit" default:"3"`
|
||||
ConnPoolDefaultMemoryLimit string `name:"connection_pool_default_memory_limit" default:"1Gi"`
|
||||
MaxDBConnections *int32 `name:"connection_pool_max_db_connections" default:"60"`
|
||||
}
|
||||
|
||||
// Config describes operator config
|
||||
|
|
|
|||
Loading…
Reference in New Issue