zrlw edited a comment on issue #8567:
URL: https://github.com/apache/dubbo/issues/8567#issuecomment-912434704


   经验证测试,昨天3.0分支提交的多实例PR满足多个reference同一接口分别设置不同回调方法的需求,粗略看了一下代码,大致处理过程如下:
   1. ReferenceConfig的init方法首先为每一个Reference创建一个consumerModel, 
每个consumerModel里面的methodConfigs保存了各自配置的onXXX回调方法;然后调用createProxy方法创建代理时,将consumerModel存入了代理对象的InvokerInvocationHandler的serviceModel属性;
   2. 
调用接口方法时,InvokerInvocationHandler的invoke方法创建RpcInvocation把serviceModel存入RpcInvocation;
   3. 
调用结束后,FutureFilter的fireXXXCallback方法调用getAsyncMethodInfo从RpcInvocation保存的serviceModel中的methodConfigs取得回调方法信息。
   @chickenlj  期待早日更新2.7.X!


-- 
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