Skip to content

Spring Webflux support for springdoc-openapi-data-rest #477

@frankruegamer

Description

@frankruegamer

springdoc-openapi-data-rest does not work in combination with Spring Webflux.
It is possible to include the dependencies alongside each other, but as soon as you add @EnableWebFlux the application crashes on bean creation with the following error:

The bean 'requestMappingHandlerAdapter', defined in class path resource [org/springframework/boot/autoconfigure/web/servlet/WebMvcAutoConfiguration$EnableWebMvcConfiguration.class], could not be registered. A bean with that name has already been defined in org.springframework.web.reactive.config.DelegatingWebFluxConfiguration and overriding is disabled.

This is because springdoc-openapi-data-rest includes the dependency spring-boot-starter-data-rest which triggers its auto configuration.

I wanted to add this dependency because of Pageable support.

I currently found no feasible workaround (excluding auto configuration classes, setting spring.main.web-application-type to reactive, etc.)

Metadata

Metadata

Assignees

No one assigned

    Labels

    enhancementNew feature or request

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions