-
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
URL被重复添加没有正确修复 #7375
Comments
看看这样解决是不是能行 #7376 |
可以,但是遍历方式不是很好,建议换成这样 private int parametersHashCode() {
int h = 0;
for (Map.Entry<String, String> next : parameters.entrySet()) {
if (Constants.TIMESTAMP_KEY.equals(next.getKey())) {
continue;
}
h += next.hashCode();
}
return h;
} |
已改 |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
这个issue #4587 对应的修复https://github.com/apache/dubbo/pull/6706/files 不正确,仍然会导致URL被重复添加,
原因是重写hashCode方法将
parameters
全部计算了, 没有剔除timestamp
https://github.com/apache/dubbo/blob/master/dubbo-common/src/main/java/org/apache/dubbo/common/URL.java#L1663
The text was updated successfully, but these errors were encountered: