envoy
envoy copied to clipboard
Doesn envoy support different path rewrite for each endpoint
for upstream endpoint, e.g.
apiVersion: networking.istio.io/v1alpha3
kind: EnvoyFilter
...
spec:
configPatches:
- applyTo: CLUSTER
match:
cluster:
service: backend.target-namespace
context: GATEWAY
patch:
operation: MERGE
value:
load_assignment:
endpoints:
- lb_endpoints:
- endpoint: # endpointA
address:
socket_address:
address: xxx.xxx.xxx.xxx
port_value: 9999
- lb_endpoints:
- endpoint: # endpointB
address:
socket_address:
address: xxx.xxx.xxx.xxx
port_value: 10000
Does above endpointA and endpointB support path rewrite like below?
- match:
- uri:
prefix: /a
rewrite:
endpointA: /endpointA/a
endpointB: /endpointB/a
- match:
- uri:
prefix: /b
rewrite:
endpointA: /endpointA/b
endpointB: /endpointB/b
i checked envoy doc, does not find any info about that.
Have any idea about this?
im wondering if this is more a question for https://github.com/envoyproxy/gateway
there is an overview of path rewriting here https://www.envoyproxy.io/docs/envoy/latest/intro/arch_overview/http/http_routing that may be helpful
I will close because http route supports path rewrite, but cluster's each endpoint does not support path rewrite