https://github.com/micro/micro/issues/293
Send request failed using micro Content-Type application/grpc+json
This commit is contained in:
张三 2019-07-27 11:11:16 +08:00 committed by GitHub
parent 4e27aac398
commit 100cb9db6b
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -127,7 +127,7 @@ func (g *grpcClient) call(ctx context.Context, node *registry.Node, req client.R
ch := make(chan error, 1)
go func() {
err := cc.Invoke(ctx, methodToGRPC(req.Service(), req.Endpoint()), req.Body(), rsp, grpc.ForceCodec(cf))
err := cc.Invoke(ctx, methodToGRPC(req.Service(), req.Endpoint()), req.Body(), rsp, grpc.CallContentSubtype(cf.Name()))
ch <- microError(err)
}()