Skip to content

Commit 26da96a

Browse files
committed
filter out inactive negs in isZoneChange
1 parent b7a97eb commit 26da96a

File tree

1 file changed

+5
-0
lines changed

1 file changed

+5
-0
lines changed

pkg/neg/syncers/transaction.go

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -843,6 +843,11 @@ func (s *transactionSyncer) isZoneChange() bool {
843843

844844
existingZones := sets.NewString()
845845
for _, ref := range negCR.Status.NetworkEndpointGroups {
846+
// For backward compatibility, an empty state is considered active.
847+
if ref.State != "" && ref.State != negv1beta1.ActiveState {
848+
continue
849+
}
850+
846851
id, err := cloud.ParseResourceURL(ref.SelfLink)
847852
if err != nil {
848853
s.logger.Error(err, "unable to parse selflink", "selfLink", ref.SelfLink)

0 commit comments

Comments
 (0)