File tree Expand file tree Collapse file tree 1 file changed +9
-9
lines changed
Expand file tree Collapse file tree 1 file changed +9
-9
lines changed Original file line number Diff line number Diff line change @@ -580,15 +580,6 @@ func (c *Cluster) checkAndSetGlobalPostgreSQLConfiguration(pod *v1.Pod, effectiv
580580 }
581581
582582 slotsToSet := make (map [string ]interface {})
583- // check if specified slots exist in config and if they differ
584- for slotName , desiredSlot := range desiredPatroniConfig .Slots {
585- if effectiveSlot , exists := effectivePatroniConfig .Slots [slotName ]; exists {
586- if reflect .DeepEqual (desiredSlot , effectiveSlot ) {
587- continue
588- }
589- }
590- slotsToSet [slotName ] = desiredSlot
591- }
592583 // check if there is any slot deletion
593584 for slotName , effectiveSlot := range effectivePatroniConfig .Slots {
594585 if desiredSlot , exists := desiredPatroniConfig .Slots [slotName ]; exists {
@@ -598,6 +589,15 @@ func (c *Cluster) checkAndSetGlobalPostgreSQLConfiguration(pod *v1.Pod, effectiv
598589 }
599590 slotsToSet [slotName ] = nil
600591 }
592+ // check if specified slots exist in config and if they differ
593+ for slotName , desiredSlot := range desiredPatroniConfig .Slots {
594+ if effectiveSlot , exists := effectivePatroniConfig .Slots [slotName ]; exists {
595+ if reflect .DeepEqual (desiredSlot , effectiveSlot ) {
596+ continue
597+ }
598+ }
599+ slotsToSet [slotName ] = desiredSlot
600+ }
601601 if len (slotsToSet ) > 0 {
602602 configToSet ["slots" ] = slotsToSet
603603 }
You can’t perform that action at this time.
0 commit comments