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 2019/12/27 05:32:55 UTC
[dubbo] branch master updated: add back missed logic in
ConsumerModel during 3.x merge. (#5539)
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/dubbo.git
The following commit(s) were added to refs/heads/master by this push:
new 6e4e6b7 add back missed logic in ConsumerModel during 3.x merge. (#5539)
6e4e6b7 is described below
commit 6e4e6b769a3b7dc5d6bad801cd394949cdfe1b7b
Author: ken.lj <ke...@gmail.com>
AuthorDate: Fri Dec 27 13:32:43 2019 +0800
add back missed logic in ConsumerModel during 3.x merge. (#5539)
---
.../main/java/org/apache/dubbo/rpc/model/ConsumerModel.java | 11 +++++++++--
1 file changed, 9 insertions(+), 2 deletions(-)
diff --git a/dubbo-common/src/main/java/org/apache/dubbo/rpc/model/ConsumerModel.java b/dubbo-common/src/main/java/org/apache/dubbo/rpc/model/ConsumerModel.java
index 4bffded..1edb403 100644
--- a/dubbo-common/src/main/java/org/apache/dubbo/rpc/model/ConsumerModel.java
+++ b/dubbo-common/src/main/java/org/apache/dubbo/rpc/model/ConsumerModel.java
@@ -66,6 +66,8 @@ public class ConsumerModel {
if (attributes != null) {
this.methodConfigs = attributes;
}
+
+ initMethodModels();
}
/**
@@ -126,9 +128,14 @@ public class ConsumerModel {
this(serviceKey, proxyObject, serviceModel, referenceConfig);
this.serviceMetadata = metadata;
+ }
- for (Method method : metadata.getServiceType().getMethods()) {
- methodModels.put(method, new ConsumerMethodModel(method));
+ public void initMethodModels() {
+ Class[] interfaceList = serviceMetadata.getTarget().getClass().getInterfaces();
+ for (Class interfaceClass : interfaceList) {
+ for (Method method : interfaceClass.getMethods()) {
+ methodModels.put(method, new ConsumerMethodModel(method));
+ }
}
}