Class ObservationWebClientCustomizer

java.lang.Object
org.springframework.boot.webclient.observation.ObservationWebClientCustomizer
All Implemented Interfaces:
WebClientCustomizer

public class ObservationWebClientCustomizer extends Object implements WebClientCustomizer
WebClientCustomizer that configures the WebClient to record request observations.
Since:
4.0.0
  • Constructor Summary

    Constructors
    Constructor
    Description
    ObservationWebClientCustomizer(io.micrometer.observation.ObservationRegistry observationRegistry, org.springframework.web.reactive.function.client.ClientRequestObservationConvention observationConvention)
    Create a new ObservationWebClientCustomizer that will configure the Observation setup on the client.
  • Method Summary

    Modifier and Type
    Method
    Description
    void
    customize(org.springframework.web.reactive.function.client.WebClient.Builder webClientBuilder)
    Callback to customize a WebClient.Builder instance.

    Methods inherited from class Object

    clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
  • Constructor Details

    • ObservationWebClientCustomizer

      public ObservationWebClientCustomizer(io.micrometer.observation.ObservationRegistry observationRegistry, org.springframework.web.reactive.function.client.ClientRequestObservationConvention observationConvention)
      Create a new ObservationWebClientCustomizer that will configure the Observation setup on the client.
      Parameters:
      observationRegistry - the registry to publish observations to
      observationConvention - the convention to use to populate observations
  • Method Details

    • customize

      public void customize(org.springframework.web.reactive.function.client.WebClient.Builder webClientBuilder)
      Description copied from interface: WebClientCustomizer
      Callback to customize a WebClient.Builder instance.
      Specified by:
      customize in interface WebClientCustomizer
      Parameters:
      webClientBuilder - the client builder to customize