有两种方法可以通过routelocator的bean或属性添加请求和响应头。但是,需要一个示例来通过一个bean作为 service-response-value
以及 service-request-value
将是一个动态值:
spring
cloud:
gateway:
default-filters:
- AddRequestHeader= service-request, service-request-value
- AddResponseHeader= service-response, service-response-value
1条答案
按热度按时间uqjltbpv1#
springcloudgateway不支持通过bean的默认过滤器
https://github.com/spring-cloud/spring-cloud-gateway/issues/263