Class ObservableReactiveSessionFactoryBean

java.lang.Object
org.springframework.beans.factory.config.AbstractFactoryBean<ReactiveSession>
org.springframework.data.cassandra.observability.ObservableReactiveSessionFactoryBean
All Implemented Interfaces:
org.springframework.beans.factory.Aware, org.springframework.beans.factory.BeanClassLoaderAware, org.springframework.beans.factory.BeanFactoryAware, org.springframework.beans.factory.DisposableBean, org.springframework.beans.factory.FactoryBean<ReactiveSession>, org.springframework.beans.factory.InitializingBean

public class ObservableReactiveSessionFactoryBean extends org.springframework.beans.factory.config.AbstractFactoryBean<ReactiveSession>
Factory bean to construct a ReactiveSession integrated with given ObservationRegistry. The required CqlSession must be associated with ObservationRequestTracker.INSTANCE to ensure proper integration with all observability components. You can use ObservableCqlSessionFactoryBean to obtain a properly configured CqlSession.
Since:
4.0
Author:
Mark Paluch
See Also:
  • Constructor Details

    • ObservableReactiveSessionFactoryBean

      public ObservableReactiveSessionFactoryBean(com.datastax.oss.driver.api.core.CqlSessionBuilder cqlSessionBuilder, io.micrometer.observation.ObservationRegistry observationRegistry)
      Parameters:
      cqlSessionBuilder - must not be null.
      observationRegistry - must not be null.
      Since:
      4.0.5
    • ObservableReactiveSessionFactoryBean

      public ObservableReactiveSessionFactoryBean(com.datastax.oss.driver.api.core.CqlSession cqlSession, io.micrometer.observation.ObservationRegistry observationRegistry)
      Parameters:
      cqlSession - must not be null.
      observationRegistry - must not be null.
  • Method Details

    • createInstance

      protected ReactiveSession createInstance()
      Specified by:
      createInstance in class org.springframework.beans.factory.config.AbstractFactoryBean<ReactiveSession>
    • getObjectType

      public Class<?> getObjectType()
      Specified by:
      getObjectType in interface org.springframework.beans.factory.FactoryBean<ReactiveSession>
      Specified by:
      getObjectType in class org.springframework.beans.factory.config.AbstractFactoryBean<ReactiveSession>
    • getRemoteServiceName

      @Nullable public String getRemoteServiceName()
    • destroy

      public void destroy()
      Specified by:
      destroy in interface org.springframework.beans.factory.DisposableBean
      Overrides:
      destroy in class org.springframework.beans.factory.config.AbstractFactoryBean<ReactiveSession>
    • setRemoteServiceName

      public void setRemoteServiceName(@Nullable String remoteServiceName)
      Set the remote service name.
      Parameters:
      remoteServiceName -