LaurenceLiZhixin commented on a change in pull request #1727:
URL: https://github.com/apache/dubbo-go/pull/1727#discussion_r793302633



##########
File path: protocol/dubbo3/dubbo3_invoker.go
##########
@@ -203,10 +203,21 @@ func (di *DubboInvoker) Invoke(ctx context.Context, 
invocation protocol.Invocati
        methodName := invocation.MethodName()
        triAttachmentWithErr := di.client.Invoke(methodName, in, 
invocation.Reply())
        result.Err = triAttachmentWithErr.GetError()
+
        result.Attrs = make(map[string]interface{})
+
        for k, v := range triAttachmentWithErr.GetAttachments() {
                result.Attrs[k] = v
        }
+
+       // Here, before making a remote call, the server may be terminated 
because the value is transmitted to the client.
+       // Because each rpc request will initiate dubboinvoker -> filter 
invoker multiple times
+       // So you need to consider using the variables called by the call chain 
for maintenance
+
+       for k, v := range invocation.Attachments() {

Review comment:
       为啥这么改,这么改就把真实返回值覆盖了呀。 Server 如果挂了就直接报错了,用不到attrs吧。 @complone 




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