-
Notifications
You must be signed in to change notification settings - Fork 26.4k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
TagRouter的stream操作导致ConsistentHashLoadBalance每次都需要重新进行hash环的映射。 #5429
Comments
i think should replace |
@CodingSinger I commit some comments for your bugfix. |
@beiwei30 Line 47 in c894e06
dubbo/dubbo-cluster/src/main/java/com/alibaba/dubbo/rpc/cluster/router/tag/TagRouter.java Lines 50 to 76 in c894e06
|
Environment
ConsistentHashLoadBalance 用到了 System.identityHashCode(invokers); 来判断 hash 值,从而判断是否有服务端的上下线操作。
而TagRouter的org.apache.dubbo.rpc.cluster.router.tag.TagRouter#filterUsingStaticTag方法中的 stream 操作会修改 invokers 的值,所以 ConsistentHashLoadBalance 受到了影响。
导致即使在服务端没有上下线操作的时候,一致性hash负载均衡算法每次都需要重新进行hash环的映射。
The text was updated successfully, but these errors were encountered: