mirror of
https://github.com/zalando/postgres-operator.git
synced 2026-10-05 00:35:43 +02:00
Assorted changes
- Update deleteConnectionPooler to include role - Rename EnableMasterConnectionPooler back to original name for backward compatiility - other minor chnages and code improvements
This commit is contained in:
@@ -607,16 +607,16 @@ def update_postgresql(namespace: str, cluster: str):
|
||||
|
||||
spec['volume'] = {'size': size}
|
||||
|
||||
if 'enableMasterConnectionPooler' in postgresql['spec']:
|
||||
cp = postgresql['spec']['enableMasterConnectionPooler']
|
||||
if 'enableConnectionPooler' in postgresql['spec']:
|
||||
cp = postgresql['spec']['enableConnectionPooler']
|
||||
if not cp:
|
||||
if 'enableMasterConnectionPooler' in o['spec']:
|
||||
del o['spec']['enableMasterConnectionPooler']
|
||||
if 'enableConnectionPooler' in o['spec']:
|
||||
del o['spec']['enableConnectionPooler']
|
||||
else:
|
||||
spec['enableMasterConnectionPooler'] = True
|
||||
spec['enableConnectionPooler'] = True
|
||||
else:
|
||||
if 'enableMasterConnectionPooler' in o['spec']:
|
||||
del o['spec']['enableMasterConnectionPooler']
|
||||
if 'enableConnectionPooler' in o['spec']:
|
||||
del o['spec']['enableConnectionPooler']
|
||||
|
||||
if 'enableReplicaConnectionPooler' in postgresql['spec']:
|
||||
cp = postgresql['spec']['enableReplicaConnectionPooler']
|
||||
|
||||
Reference in New Issue
Block a user