tokers commented on a change in pull request #742:
URL:
https://github.com/apache/apisix-ingress-controller/pull/742#discussion_r748955570
##########
File path: pkg/ingress/compare.go
##########
@@ -42,7 +43,7 @@ func (c *Controller) CompareResources(ctx context.Context)
error {
consumerMapA6 = make(map[string]string)
)
// watchingNamespace == nil means to monitor all namespaces
- if c.watchingNamespace == nil {
+ if !validation.HasValueInSyncMap(c.watchingNamespace) {
Review comment:
This check is not safe. The result is only correct at a very specific
point-in-time, which means the map might contains some elements after you check
it. Please assess the impacts. If necessary, use a mutex.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]