With Spring Boot 3.1.6, a Spring WebFlux application with Micrometer Observation would fail to start when multiple beans of type ServerRequestObservationConvention
are defined, which I consider expected behavior. However, with Spring Boot 3.2.0 this behavior changed, and now you don't get a startup failure when multiple ServerRequestObservationConvention
beans are defined, but silently DefaultServerRequestObservationConvention
is used. I think this is unexpected and confusing behavior.
I've created https://github.com/breun/spring-boot-reactive-observation-convention-issue to illustrate this issue. See the tests on the spring-boot-3.1
and spring-boot-3.2
branches of this project.
Comment From: scottfrederick
The reason that you're no longer getting the exception when multiple ServerRequestObservationConvention
beans are created is that the WebFlux observation auto-configuration no longer uses beans of this type. See spring-projects/spring-boot#37344 for the background on this change. This is not currently mentioned in the 3.2 release notes, so we should add something there.
Comment From: bclozel
We'll align the Framework behavior with the previous Spring Boot setup.