Class MongoSpaceDataSourceBeanFactory

java.lang.Object
com.gigaspaces.persistency.MongoSpaceDataSourceBeanFactory
All Implemented Interfaces:
ClusterInfoAware, org.springframework.beans.factory.DisposableBean, org.springframework.beans.factory.FactoryBean<MongoSpaceDataSource>, org.springframework.beans.factory.InitializingBean

public class MongoSpaceDataSourceBeanFactory extends Object implements org.springframework.beans.factory.FactoryBean<MongoSpaceDataSource>, org.springframework.beans.factory.InitializingBean, org.springframework.beans.factory.DisposableBean, ClusterInfoAware
  • Constructor Details

    • MongoSpaceDataSourceBeanFactory

      public MongoSpaceDataSourceBeanFactory()
  • Method Details

    • setMongoClientConnector

      public void setMongoClientConnector(MongoClientConnector mongoClientConnector)
    • destroy

      public void destroy() throws Exception
      Specified by:
      destroy in interface org.springframework.beans.factory.DisposableBean
      Throws:
      Exception
    • afterPropertiesSet

      public void afterPropertiesSet() throws Exception
      Specified by:
      afterPropertiesSet in interface org.springframework.beans.factory.InitializingBean
      Throws:
      Exception
    • getObject

      public MongoSpaceDataSource getObject() throws Exception
      Specified by:
      getObject in interface org.springframework.beans.factory.FactoryBean<MongoSpaceDataSource>
      Throws:
      Exception
    • getObjectType

      public Class<?> getObjectType()
      Specified by:
      getObjectType in interface org.springframework.beans.factory.FactoryBean<MongoSpaceDataSource>
    • isSingleton

      public boolean isSingleton()
      Specified by:
      isSingleton in interface org.springframework.beans.factory.FactoryBean<MongoSpaceDataSource>
    • setClusterInfo

      public void setClusterInfo(ClusterInfo clusterInfo)
      Description copied from interface: ClusterInfoAware
      Sets the cluster information.

      Note, the cluster information is obtained externally from the application context which means that this feature need to be supported by specific containers (and is not supported by plain Spring application context). This means that beans that implement ClusterInfoAware should take into account the fact that the cluster info provided might be null.

      Specified by:
      setClusterInfo in interface ClusterInfoAware
      Parameters:
      clusterInfo - The cluster information to be injected