Skip to content

Example of spring routing and filtering using spring-cloud-starter-netflix-zuul

Notifications You must be signed in to change notification settings

itqpleyva/spring-routing-filtering

Repository files navigation

spring-routing-filtering

Example of spring routing and filtering using spring-cloud-starter-netflix-zuul

Example of route filtering using spring-cloud-starter-netflix-zuul

Dependencies:

  • spring-cloud-starter-netflix-zuul

In this case, a rest RoutingFilteringExample microservice is created that provides two endpoints:

  • localhost: 8080 / in
  • localhost: 8080 / out

In addition, a GatewayServiceZuul gateway is created to filter the routes of the rest service, in this service a FilterPre filter is created that runs before consuming any of the endpoints in RoutingFilteringExample microservice

obtaining as a result a console log message with the characteristics of the executed request

For the GatewayServiceZuul to function as a reverse proxy it is necessary to add the @EnableZuulProxy annotation and inject a bean of the FilterPre class

About

Example of spring routing and filtering using spring-cloud-starter-netflix-zuul

Topics

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages