org.infinispan.loaders.decorators
Class SingletonStoreConfig

java.lang.Object
  extended by org.infinispan.config.AbstractConfigurationBean
      extended by org.infinispan.config.AbstractNamedCacheConfigurationBean
          extended by org.infinispan.loaders.decorators.AbstractDecoratorConfigurationBean
              extended by org.infinispan.loaders.decorators.SingletonStoreConfig
All Implemented Interfaces:
Serializable, Cloneable, CloneableConfigurationComponent, JAXBUnmarshallable, CacheLoaderConfig, CacheStoreConfig

public class SingletonStoreConfig
extends AbstractDecoratorConfigurationBean

SingletonStore is a delegating cache store used for situations when only one instance in a cluster should interact with the underlying store. The coordinator of the cluster will be responsible for the underlying CacheStore. SingletonStore is a simply facade to a real CacheStore implementation. It always delegates reads to the real CacheStore.

Since:
4.0
Author:
Manik Surtani, Vladimir Blagojevic
See Also:
Configuration reference, Serialized Form

Field Summary
protected  Boolean enabled
           
protected  Long pushStateTimeout
           
protected  Boolean pushStateWhenCoordinator
           
 
Fields inherited from class org.infinispan.config.AbstractNamedCacheConfigurationBean
cr
 
Fields inherited from class org.infinispan.config.AbstractConfigurationBean
overriddenConfigurationElements
 
Constructor Summary
SingletonStoreConfig()
           
 
Method Summary
 void accept(ConfigurationBeanVisitor v)
           
 SingletonStoreConfig clone()
           
 SingletonStoreConfig enabled(Boolean singletonStoreEnabled)
          If true, the singleton store cache store is enabled.
 Long getPushStateTimeout()
           
 Boolean isPushStateWhenCoordinator()
           
 Boolean isSingletonStoreEnabled()
           
 SingletonStoreConfig pushStateTimeout(Long pushStateTimeout)
          If pushStateWhenCoordinator is true, this property sets the maximum number of milliseconds that the process of pushing the in-memory state to the underlying cache loader should take.
 SingletonStoreConfig pushStateWhenCoordinator(Boolean pushStateWhenCoordinator)
          If true, when a node becomes the coordinator, it will transfer in-memory state to the underlying cache store.
 void setPushStateTimeout(Long pushStateTimeout)
          Deprecated. The visibility of this method will be reduced. Use pushStateTimeout(Long) instead.
 void setPushStateWhenCoordinator(Boolean pushStateWhenCoordinator)
          Deprecated. The visibility of this method will be reduced. Use pushStateWhenCoordinator(Boolean) instead.
 void setSingletonStoreEnabled(Boolean singletonStoreEnabled)
          Deprecated. The visibility of this method will be reduced. Use CacheStoreConfig.singletonStore() instead.
 
Methods inherited from class org.infinispan.loaders.decorators.AbstractDecoratorConfigurationBean
asyncStore, build, fetchPersistentState, getAsyncStoreConfig, getCacheLoaderClassName, getClassLoader, getPurgerThreads, getSingletonStoreConfig, ignoreModifications, isFetchPersistentState, isIgnoreModifications, isPurgeOnStartup, isPurgeSynchronously, purgeOnStartup, purgerThreads, purgeSynchronously, setAsyncStoreConfig, setCacheLoaderClassName, setCacheStoreConfig, setFetchPersistentState, setIgnoreModifications, setPurgeOnStartup, setPurgeSynchronously, setSingletonStoreConfig, singletonStore
 
Methods inherited from class org.infinispan.config.AbstractNamedCacheConfigurationBean
hasComponentStarted, inject
 
Methods inherited from class org.infinispan.config.AbstractConfigurationBean
testImmutability, toTypedProperties, toTypedProperties, uc, willUnmarshall
 
Methods inherited from class java.lang.Object
equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

enabled

protected Boolean enabled

pushStateWhenCoordinator

protected Boolean pushStateWhenCoordinator

pushStateTimeout

protected Long pushStateTimeout
Constructor Detail

SingletonStoreConfig

public SingletonStoreConfig()
Method Detail

isSingletonStoreEnabled

public Boolean isSingletonStoreEnabled()

setSingletonStoreEnabled

@Deprecated
public void setSingletonStoreEnabled(Boolean singletonStoreEnabled)
Deprecated. The visibility of this method will be reduced. Use CacheStoreConfig.singletonStore() instead.

If true, the singleton store cache store is enabled.

Parameters:
singletonStoreEnabled -

enabled

public SingletonStoreConfig enabled(Boolean singletonStoreEnabled)
If true, the singleton store cache store is enabled.

Parameters:
singletonStoreEnabled -

isPushStateWhenCoordinator

public Boolean isPushStateWhenCoordinator()

setPushStateWhenCoordinator

@Deprecated
public void setPushStateWhenCoordinator(Boolean pushStateWhenCoordinator)
Deprecated. The visibility of this method will be reduced. Use pushStateWhenCoordinator(Boolean) instead.

If true, when a node becomes the coordinator, it will transfer in-memory state to the underlying cache store. This can be very useful in situations where the coordinator crashes and there's a gap in time until the new coordinator is elected.

Parameters:
pushStateWhenCoordinator -

pushStateWhenCoordinator

public SingletonStoreConfig pushStateWhenCoordinator(Boolean pushStateWhenCoordinator)
If true, when a node becomes the coordinator, it will transfer in-memory state to the underlying cache store. This can be very useful in situations where the coordinator crashes and there's a gap in time until the new coordinator is elected.

Parameters:
pushStateWhenCoordinator -

getPushStateTimeout

public Long getPushStateTimeout()

setPushStateTimeout

@Deprecated
public void setPushStateTimeout(Long pushStateTimeout)
Deprecated. The visibility of this method will be reduced. Use pushStateTimeout(Long) instead.

If pushStateWhenCoordinator is true, this property sets the maximum number of milliseconds that the process of pushing the in-memory state to the underlying cache loader should take.

Parameters:
pushStateTimeout -

pushStateTimeout

public SingletonStoreConfig pushStateTimeout(Long pushStateTimeout)
If pushStateWhenCoordinator is true, this property sets the maximum number of milliseconds that the process of pushing the in-memory state to the underlying cache loader should take.

Parameters:
pushStateTimeout -

clone

public SingletonStoreConfig clone()
Specified by:
clone in interface CloneableConfigurationComponent
Specified by:
clone in interface CacheLoaderConfig
Overrides:
clone in class AbstractDecoratorConfigurationBean

accept

public void accept(ConfigurationBeanVisitor v)

-->

Copyright © 2011 JBoss, a division of Red Hat. All Rights Reserved.