CrazyHZM commented on a change in pull request #8455:
URL: https://github.com/apache/dubbo/pull/8455#discussion_r686489177



##########
File path: 
dubbo-common/src/main/java/org/apache/dubbo/rpc/model/ConsumerModel.java
##########
@@ -64,7 +66,20 @@ public ConsumerModel(String serviceKey
         this.referenceConfig = referenceConfig;
     }
 
-    public void init(Map<String, AsyncMethodInfo> attributes) {
+
+    public void initMethodModels(List<MethodConfig> methodConfigs) {
+
+        Map<String, AsyncMethodInfo> attributes = null;
+        if (CollectionUtils.isNotEmpty(methodConfigs)) {
+            attributes = new HashMap<>(16);
+            for (MethodConfig methodConfig : methodConfigs) {
+                AsyncMethodInfo asyncMethodInfo = 
methodConfig.convertMethodConfig2AsyncInfo();

Review comment:
       In fact, ConsumerModel is not that simple, and the initMethodModels 
method of ConsumerModel is for MethodModel. There is nothing wrong with the 
association between MethodModel and MethodConfig.




-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]



---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to