Skip to content

Conversation

@artembilan
Copy link
Member

The observation propagation doesn't work in multi-binder configuration

  • Remove ObservationAutoConfiguration since it is not visible in case of multi-binder configuration
  • Instead move setObservationEnabled flag setting to the RabbitMessageChannelBinder
  • Add io.micrometer.observation.ObservationRegistry into shared.beans to make it visible for binder-specific application context
  • Add RabbitMultiBinderObservationTests integration test where Rabbit Binder is in multi-binder environment

As a side effect this fixes an observation propagation for Kafka binder as well in the multi-binder environment. Its configuration is OK, but an ObservationRegistry must make it visible for the binder-specific application context. See the mentioned shared.beans

Related to #2901 Also see #2902 for possible evolution

The observation propagation doesn't work in multi-binder configuration

* Remove `ObservationAutoConfiguration` since it is not visible in case of multi-binder configuration
* Instead move `setObservationEnabled` flag setting to the `RabbitMessageChannelBinder`
* Add `io.micrometer.observation.ObservationRegistry` into `shared.beans` to make it visible for binder-specific application context
* Add `RabbitMultiBinderObservationTests` integration test where Rabbit Binder is in multi-binder environment

As a side effect this fixes an observation propagation for Kafka binder as well in the multi-binder environment.
Its configuration is OK, but an `ObservationRegistry` must make it visible for the binder-specific application context.
See the mentioned `shared.beans`

Related to spring-cloud#2901
Also see spring-cloud#2902 for possible evolution
@artembilan artembilan force-pushed the multi_binder_observation branch from f48e4a1 to fd00668 Compare February 14, 2024 21:51
@sobychacko
Copy link
Contributor

@artembilan Looks good. One small comment - some classes are missing copyright updates to 2024 and your author tag.

@sobychacko sobychacko merged commit 3e24d33 into spring-cloud:main Feb 14, 2024
@sobychacko sobychacko added this to the 4.1.1 milestone Feb 15, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants