DUBBO-68 兼容URL的equals。

git-svn-id: http://code.alibabatech.com/svn/dubbo/trunk@1247 1a56cb94-b969-4eaa-88fa-be21384802f2
This commit is contained in:
william.liangf 2012-03-10 19:49:33 +00:00
parent 4c682e8e9b
commit 81d0d78586
1 changed files with 10 additions and 1 deletions

View File

@ -114,7 +114,16 @@ public abstract class AbstractRegistryService implements RegistryService {
}
List<URL> urls = registered.get(service);
if (urls != null) {
urls.remove(url);
URL deleteURL = null;
for (URL u : urls) {
if (u.toIdentityString().equals(url.toIdentityString())) {
deleteURL = u;
break;
}
}
if (deleteURL != null) {
urls.remove(deleteURL);
}
}
removeListener(service, listener);
}