Check link is grpc
This commit is contained in:
parent
4e2339749c
commit
1af82df8b1
@ -490,7 +490,8 @@ func (p *Proxy) serveRequest(ctx context.Context, link client.Client, service, e
|
|||||||
defer stream.Close()
|
defer stream.Close()
|
||||||
|
|
||||||
// if we receive a grpc stream we have to refire the initial request
|
// if we receive a grpc stream we have to refire the initial request
|
||||||
if c, ok := req.Codec().(codec.Codec); ok && c.String() == "grpc" {
|
c, ok := req.Codec().(codec.Codec)
|
||||||
|
if ok && c.String() == "grpc" && link.String() == "grpc" {
|
||||||
// get the header from client
|
// get the header from client
|
||||||
hdr := req.Header()
|
hdr := req.Header()
|
||||||
msg := &codec.Message{
|
msg := &codec.Message{
|
||||||
|
Loading…
Reference in New Issue
Block a user