RainYuY commented on code in PR #15876:
URL: https://github.com/apache/dubbo/pull/15876#discussion_r2626043328


##########
dubbo-cluster/src/main/java/org/apache/dubbo/rpc/cluster/router/tag/TagStateRouter.java:
##########
@@ -105,6 +108,17 @@ public BitList<Invoker<T>> doRoute(
             return invokers;
         }
 
+        String tag = StringUtils.isEmpty(invocation.getAttachment(TAG_KEY))
+                ? url.getParameter(TAG_KEY)
+                : invocation.getAttachment(TAG_KEY);
+        if (ANY_VALUE.equals(tag)
+                || (StringUtils.isEmpty(tag) && 
BROADCAST_CLUSTER.equals(url.getParameter(CLUSTER_KEY)))) {

Review Comment:
   No, we shouldn’t assume that null tags or empty tags can be used to route 
all invokers. This will cause some incompatible issues, and I believe it’s not 
in line with common sense.



-- 
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]


---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to