Open dspo opened 2 years ago
Is your feature request related to a problem? Please describe in details
我有如下的路由
[{ "match": { "PathSpecifier": { "Prefix": "/web/" } }, "Action": { "Route": { "ClusterSpecifier": { "Cluster": "my-web" }, "prefix_rewrite": "/", "HostRewriteSpecifier": { "AutoHostRewrite": {} } } } }, { "match": { "PathSpecifier": { "Prefix": "/web" } }, "Action": { "Route": { "ClusterSpecifier": { "Cluster": "my-web" }, "prefix_rewrite": "/", "HostRewriteSpecifier": { "AutoHostRewrite": {} } } } }]
假设请求 {gateway-domain}/web/abc , 上游服务 my-web 返回 302 Found location: /abc/ . 此时如果 envoy 不处理该响应的话, 浏览器就会访问 {gateway-domain}/abc/ 了.
{gateway-domain}
对标 Nginx http://nginx.org/en/docs/http/ngx_http_proxy_module.html#proxy_redirect
A clear and concise description of what you want to happen. You can explain more about input of the feature, and output of it.
envoy 要么内部处理该重定向, 自动请求新的地址, 将正确结果返回客户端, 要么修改 location 字段后再返回给客户端.
Add any other context or screenshots about the feature request here.
内部重定向是支持的:https://www.envoyproxy.io/docs/envoy/latest/api-v3/config/route/v3/route_components.proto#envoy-v3-api-msg-config-route-v3-internalredirectpolicy
Why do you need it?
Is your feature request related to a problem? Please describe in details
我有如下的路由
假设请求
{gateway-domain}
/web/abc , 上游服务 my-web 返回 302 Found location: /abc/ . 此时如果 envoy 不处理该响应的话, 浏览器就会访问{gateway-domain}
/abc/ 了.对标 Nginx http://nginx.org/en/docs/http/ngx_http_proxy_module.html#proxy_redirect
How could it be?
A clear and concise description of what you want to happen. You can explain more about input of the feature, and output of it.
envoy 要么内部处理该重定向, 自动请求新的地址, 将正确结果返回客户端, 要么修改 location 字段后再返回给客户端.
Other related information
Add any other context or screenshots about the feature request here.