OpenAPI-Swagger webflux Spring boot 3

I don't know why in my Swagger, I see only one of my two routes

@Configuration
public class IngredientRouter {

    private static final String BASE_URL = "/ingredient/";

    @RouterOperations({
            @RouterOperation(path = BASE_URL, method = RequestMethod.GET, beanClass = IngredientService.class, beanMethod = "getAllIngredients"),
            @RouterOperation(path = BASE_URL + "{name}", method = RequestMethod.GET,beanClass = IngredientService.class, beanMethod = "getAllIngredientsStartingWith")
    })
    @Bean
    public RouterFunction<ServerResponse> ingredientRoute(IngredientHandler handler) {
        return RouterFunctions
                .route(GET(BASE_URL).and(accept(MediaType.APPLICATION_JSON)), handler::getAllIngredients)
                .andRoute(GET(BASE_URL + "{name}").and(accept(MediaType.APPLICATION_JSON)), handler::getAllIngredientsStartingWith);
    }
Was this page helpful?