/webflux-spring-security-demo

Demonstrates no Spring-Security logging with Spring-Boot and WebFlux

Primary LanguageKotlin

No Spring-Security logging with Spring-Boot and WebFlux

Summary

I cannot get Spring-Security to log anything in a simple Spring-Boot WebFlux application. I assume I must be doing something wrong because my searches have only turned up this unanswered SO question.

Actual Behavior

No Spring-Boot logging entries appear in terminal window after running ./gradlew bootRun.

Expected Behavior

Detailed logging entries as if using MVC. I followed the same steps to reproduce as shown below, substituting "Web" for "Reactive Web," and it works as expected.

Configuration

macOS 10.13.6 java version "1.8.0_181"

Version

I tried Spring-Booot versions 2.0.4, 2.1.0.M2, and 2.1.0.SNAPSHOT.

Sample

https://github.com/kensiprell/webflux-spring-security-demo

Steps to Reproduce

  1. Go to https://start.spring.io.

  2. Choose Gradle, Kotlin or Java, and a Boot version.

  3. Add 'Security' and 'Reactive Web' to the dependencies and generate the project.

  4. Unarchive demo.zip and cd demo/.

  5. Edit ./src/main/resources/application.properties and add a line that should increase the logging level: logging.level.root=DEBUG or logging.level.org.springframework.security=DEBUG

  6. ./gradlew bootRun

  7. Open http://localhost:8080 in a browser.