Spring Cloud PrefixPath GatewayFilter工厂
PrefixPath GatewayFilter工厂采用单个prefix参数。
application.yml。
spring: cloud: gateway: routes: - id: prefixpath_route uri: https://example.org filters: - PrefixPath=/mypath
这会将/mypath作为所有匹配请求的路径的前缀。因此,对/hello的请求将被发送到/mypath/hello。