Move observation support classes to scheduling.support package

Avoids a package cycle between config and support (only config->support allowed).

See gh-29883
This commit is contained in:
Juergen Hoeller
2023-07-08 14:57:02 +02:00
parent 8fb412ea74
commit f0fe58f0ec
9 changed files with 44 additions and 39 deletions

View File

@@ -91,7 +91,7 @@ This can be done by declaring a `SchedulingConfigurer` bean that sets the observ
include-code::./ObservationSchedulingConfigurer[]
It is using the `org.springframework.scheduling.config.DefaultScheduledTaskObservationConvention` by default, backed by the `ScheduledTaskObservationContext`.
It is using the `org.springframework.scheduling.support.DefaultScheduledTaskObservationConvention` by default, backed by the `ScheduledTaskObservationContext`.
You can configure a custom implementation on the `ObservationRegistry` directly.
During the execution of the scheduled method, the current observation is restored in the `ThreadLocal` context or the Reactor context (if the scheduled method returns a `Mono` or `Flux` type).