File tree Expand file tree Collapse file tree 1 file changed +14
-1
lines changed Expand file tree Collapse file tree 1 file changed +14
-1
lines changed Original file line number Diff line number Diff line change @@ -472,7 +472,20 @@ func equalSyncWork(a, b *SyncWork) bool {
472
472
if (a == nil && b != nil ) || (a != nil && b == nil ) {
473
473
return false
474
474
}
475
- return equalUpdate (a .Desired , b .Desired ) && reflect .DeepEqual (a .Overrides , b .Overrides )
475
+ sameVersion := equalUpdate (a .Desired , b .Desired )
476
+ overridesEqual := reflect .DeepEqual (a .Overrides , b .Overrides )
477
+
478
+ if ! sameVersion && ! overridesEqual {
479
+ klog .V (5 ).Info ("Detected version and overrides changes" )
480
+ return false
481
+ } else if ! sameVersion {
482
+ klog .V (5 ).Info ("Detected version change" )
483
+ return false
484
+ } else if ! overridesEqual {
485
+ klog .V (5 ).Info ("Detected overrides change" )
486
+ return false
487
+ }
488
+ return true
476
489
}
477
490
478
491
// updateStatus records the current status of the sync action for observation
You can’t perform that action at this time.
0 commit comments