mirror of
https://github.com/zalando/postgres-operator.git
synced 2026-10-05 14:43:59 +02:00
Avoid unneccessary update events
This commit is contained in:
@@ -487,7 +487,7 @@ func (c *Controller) postgresqlUpdate(prev, cur interface{}) {
|
||||
if pgOld != nil && pgNew != nil {
|
||||
// Avoid the inifinite recursion for status updates
|
||||
if reflect.DeepEqual(pgOld.Spec, pgNew.Spec) {
|
||||
if pgNew.Annotations != nil && pgOld.Annotations != nil && !reflect.DeepEqual(pgNew.Annotations, pgOld.Annotations) {
|
||||
if reflect.DeepEqual(pgNew.Annotations, pgOld.Annotations) {
|
||||
return
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user