Spring Boot 2.2.2-RELEASE
Configure the following dependencies:
<dependency>
<groupId>org.springframework.boot</groupId>
<artifactId>spring-boot-starter-security</artifactId>
</dependency>
<dependency>
<groupId>org.springframework.boot</groupId>
<artifactId>spring-boot-starter-webflux</artifactId>
</dependency>
<dependency>
<groupId>org.springframework.boot</groupId>
<artifactId>spring-boot-starter-data-rest</artifactId>
</dependency>
Cannot customize the Web Security configuration:
@Bean
public SecurityWebFilterChain springSecurityFilterChain(ServerHttpSecurity http)
Fails with error:
***************************
APPLICATION FAILED TO START
***************************
Description:
Parameter 0 of method springSecurityFilterChain in io.wordlift.widgetservice.WidgetApplication required a bean of type 'org.springframework.security.config.web.server.ServerHttpSecurity' that could not be found.
Action:
Consider defining a bean of type 'org.springframework.security.config.web.server.ServerHttpSecurity' in your configuration.
This is because spring-boot-starter-data-rest brings spring-boot-starter-web which turns off WebFlux.
The expected result would be the starter to be agnostic and to support WebFlux.
Comment From: ziodave
Going through the Spring Data REST documentation again, it seems to only support MVC.
https://docs.spring.io/spring-data/rest/docs/current/reference/html/#install-chapter
Comment From: ziodave
Confirmed: https://jira.spring.io/browse/SPR-14878