You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@dubbo.apache.org by li...@apache.org on 2018/10/24 02:41:53 UTC
[incubator-dubbo] branch master updated: Merge pull request#2679,
consumer throws RpcException when RegistryDirectory notify in high
QPS.
This is an automated email from the ASF dual-hosted git repository.
liujun pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/incubator-dubbo.git
The following commit(s) were added to refs/heads/master by this push:
new f2b6f07 Merge pull request#2679, consumer throws RpcException when RegistryDirectory notify in high QPS.
f2b6f07 is described below
commit f2b6f07f5a0d70b2b3bd0368a34168a05819cd13
Author: Ian Luo <ia...@gmail.com>
AuthorDate: Wed Oct 24 10:41:44 2018 +0800
Merge pull request#2679, consumer throws RpcException when RegistryDirectory notify in high QPS.
Fixes #2016
---
.../main/java/org/apache/dubbo/rpc/protocol/AbstractInvoker.java | 6 +++---
1 file changed, 3 insertions(+), 3 deletions(-)
diff --git a/dubbo-rpc/dubbo-rpc-api/src/main/java/org/apache/dubbo/rpc/protocol/AbstractInvoker.java b/dubbo-rpc/dubbo-rpc-api/src/main/java/org/apache/dubbo/rpc/protocol/AbstractInvoker.java
index e4eba3c..fd0cca6 100644
--- a/dubbo-rpc/dubbo-rpc-api/src/main/java/org/apache/dubbo/rpc/protocol/AbstractInvoker.java
+++ b/dubbo-rpc/dubbo-rpc-api/src/main/java/org/apache/dubbo/rpc/protocol/AbstractInvoker.java
@@ -126,10 +126,10 @@ public abstract class AbstractInvoker<T> implements Invoker<T> {
@Override
public Result invoke(Invocation inv) throws RpcException {
+ // if invoker is destroyed due to address refresh from registry, let's allow the current invoke to proceed
if (destroyed.get()) {
- throw new RpcException("Rpc invoker for service " + this + " on consumer " + NetUtils.getLocalHost()
- + " use dubbo version " + Version.getVersion()
- + " is DESTROYED, can not be invoked any more!");
+ logger.warn("Invoker for service " + this + " on consumer " + NetUtils.getLocalHost() + " is destroyed, "
+ + ", dubbo version is " + Version.getVersion() + ", this invoker should not be used any longer");
}
RpcInvocation invocation = (RpcInvocation) inv;
invocation.setInvoker(this);