Skip to content

TagRouter的stream操作导致ConsistentHashLoadBalance每次都需要重新进行hash环的映射。 #5429

Description

@thisiswanghy

Environment

  • Dubbo version: 2.7.4.1

ConsistentHashLoadBalance 用到了 System.identityHashCode(invokers); 来判断 hash 值,从而判断是否有服务端的上下线操作。
而TagRouter的org.apache.dubbo.rpc.cluster.router.tag.TagRouter#filterUsingStaticTag方法中的 stream 操作会修改 invokers 的值,所以 ConsistentHashLoadBalance 受到了影响。
导致即使在服务端没有上下线操作的时候,一致性hash负载均衡算法每次都需要重新进行hash环的映射。

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Fields

    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions