Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[Spring Cloud Gateway MVC] route vs controller precedence #3530

Open
lmbai opened this issue Sep 19, 2024 · 0 comments
Open

[Spring Cloud Gateway MVC] route vs controller precedence #3530

lmbai opened this issue Sep 19, 2024 · 0 comments

Comments

@lmbai
Copy link

lmbai commented Sep 19, 2024

Describe the bug
when use the Spring Cloud Gateway MVC with a self defined web controller, the route take more priority than controller. This is different behaviour with the Reactive Gateway

Sample
we have a controller

@GetMapping("/items/{Id}")

we also have a route definition

    gateway:
      mvc:
        routes:
          - id: Fallback
            uri: ${downtream-uri}
            predicates:
              - Path=/items/**

the request didn't reach to the controller, it directly route to downsteam

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

1 participant