From 050cd5c64e99ced96dfb408980755ba4a6a3fa46 Mon Sep 17 00:00:00 2001 From: lixiangyang Date: Thu, 22 Aug 2024 10:55:46 +0800 Subject: [PATCH] fix: raw call also needs to return res metadata --- client/client.go | 2 ++ 1 file changed, 2 insertions(+) diff --git a/client/client.go b/client/client.go index 34a26bb5..0fb2b2b7 100644 --- a/client/client.go +++ b/client/client.go @@ -688,6 +688,7 @@ func (client *Client) input() { if call.Raw { call.Metadata, call.Reply, _ = convertRes2Raw(res) call.Metadata[XErrorMessage] = call.Error.Error() + call.ResMetadata = res.Metadata } else if len(res.Payload) > 0 { data := res.Payload codec := share.Codecs[res.SerializeType()] @@ -699,6 +700,7 @@ func (client *Client) input() { default: if call.Raw { call.Metadata, call.Reply, _ = convertRes2Raw(res) + call.ResMetadata = res.Metadata } else { data := res.Payload if len(data) > 0 {