Spring Cloud Gateway: Apply Custom Filter to RouterFunction

249 Views Asked by At

In my spring cloud gateway I created a global filter that applies to standard routes fine, but I want to apply this same filter to a RouterFunction.

How do I go about passing my custom filter to the RouterFunctions.route().filter() ?

1

There are 1 best solutions below

1
JIBON SARKER On

This project provides an API Gateway built on top of the Spring Ecosystem, including: Spring 5, Spring Boot 2 and Project Reactor. Spring Cloud Gateway aims to provide a simple,