Description
Spring Boot version
3.0.4
Reproducible example
https://github.com/violetagg/netty-observation-repro
Problem description
I would like to use Reactor Netty tracing capabilities in Spring Boot application.
For this purpose I need to reuse the ObservationRegistry
created by Spring Boot and to add ObservationHandler
s provided by Reactor Netty.
Observations:
- If I only reuse the
ObservationRegistry
without adding theObservationHandler
s provided by Reactor Netty - the tracing information is correctly visualised but the span tags are duplicated and one and the same Timer object is created every time.
-
If I reuse the
ObservationRegistry
and addObservationHandler
s provided by Reactor Netty - the tracing information is NOT correctly visualised. -
If I reuse the
ObservationRegistry
, addObservationHandler
s provided by Reactor Netty and in addition add all defaultObservationHandler
s provided by Spring Boot - the tracing information is correctly visualised, the span tags are not duplicated and one and the same Timer object is created only once. Reactor Netty tracing capabilities are working as expected.
Desired solution
Spring Boot should preserve the default ObservationHandler
s when custom ObservationHandler
s are added to the configuration.