问题
istio EnvoyFilter is not converting http1X to http2X(GRPXC) service
I gave GRP Service in Azure AKS and istio-1.1.6 my GRPC service is listening 50051 port , I have EnvoyFilter filter for trascoding of JSON to GRPC but on my service I am still getting http 1X request even I am calling it through GRPC Client (Http2.o) request
Envoy Filer
apiVersion: networking.istio.io/v1alpha3
kind: EnvoyFilter
metadata:
name: envoy-proxy
namespace: istio-system
spec:
filters:
- listenerMatch:
listenerType: GATEWAY (tried with INBOUD_SIDECAR too)
listenerProtocol: HTTP
insertPosition:
index: BEFORE
relativeTo: envoy.router
filterName: envoy.grpc_json_transcoder
filterType: HTTP
filterConfig:
proto_descriptor: "/mnt/azure/descriptor_set.pb"
services:
- x.x.x.HelloService
printOptions:
alwaysPrintPrimitiveFields: True
GRPC Service
---
apiVersion: v1
kind: Service
metadata:
creationTimestamp: null
labels:
app: c7-service
name: c7-service
spec:
type: ClusterIP
ports:
- name: "50051"
protocol: TCP
port: 80
targetPort: 50051
selector:
app: c7-service
status:
loadBalancer: {}
Error:
Jun 09, 2019 12:13:59 AM io.grpc.netty.shaded.io.grpc.netty.NettyServerTransport notifyTerminated
INFO: Transport failed
io.grpc.netty.shaded.io.netty.handler.codec.http2.Http2Exception: Unexpected HTTP/1.x request: POST
at io.grpc.netty.shaded.io.netty.handler.codec.http2.Http2Exception.connectionError(Http2Exception.java:85)
at io.grpc.netty.shaded.io.netty.handler.codec.http2.Http2ConnectionHandler$PrefaceDecoder.readClientPrefaceString(Http2ConnectionHandler.java:314)
来源:https://stackoverflow.com/questions/56512247/envoyfilter-filter-for-grpc-json-transcoder-in-istio