Class ResponseCacheGatewayFilter

java.lang.Object
org.springframework.cloud.gateway.filter.factory.cache.ResponseCacheGatewayFilter
All Implemented Interfaces:
GatewayFilter, ShortcutConfigurable, org.springframework.core.Ordered

public class ResponseCacheGatewayFilter extends Object implements GatewayFilter, org.springframework.core.Ordered
LocalResponseCache Gateway Filter that stores HTTP Responses in a cache, so latency and upstream overhead is reduced.
Author:
Marta Medio, Ignacio Lozano
  • Constructor Details

    • ResponseCacheGatewayFilter

      public ResponseCacheGatewayFilter(ResponseCacheManager responseCacheManager)
  • Method Details

    • filter

      public reactor.core.publisher.Mono<Void> filter(org.springframework.web.server.ServerWebExchange exchange, GatewayFilterChain chain)
      Description copied from interface: GatewayFilter
      Process the Web request and (optionally) delegate to the next WebFilter through the given GatewayFilterChain.
      Specified by:
      filter in interface GatewayFilter
      Parameters:
      exchange - the current server exchange
      chain - provides a way to delegate to the next filter
      Returns:
      Mono<Void> to indicate when request processing is complete
    • getOrder

      public int getOrder()
      Specified by:
      getOrder in interface org.springframework.core.Ordered