Class PersistenceConfiguration
- java.lang.Object
-
- org.infinispan.configuration.cache.PersistenceConfiguration
-
- All Implemented Interfaces:
Matchable<PersistenceConfiguration>,BaseConfigurationInfo,ConfigurationInfo
public class PersistenceConfiguration extends java.lang.Object implements Matchable<PersistenceConfiguration>, ConfigurationInfo
Configuration for stores.
-
-
Field Summary
Fields Modifier and Type Field Description static AttributeDefinition<java.lang.Integer>AVAILABILITY_INTERVALstatic AttributeDefinition<java.lang.Integer>CONNECTION_ATTEMPTSstatic AttributeDefinition<java.lang.Integer>CONNECTION_INTERVALstatic AttributeDefinition<java.lang.Boolean>PASSIVATION
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description AttributeSetattributes()intavailabilityInterval()intconnectionAttempts()intconnectionInterval()booleanequals(java.lang.Object obj)java.lang.BooleanfetchPersistentState()Loops through all individual cache loader configs and checks if fetchPersistentState is set on any of themElementDefinitiongetElementDefinition()inthashCode()booleanpassivation()If true, data is only written to the cache store when it is evicted from memory, a phenomenon known as 'passivation'.java.lang.Booleanpreload()Loops through all individual cache loader configs and checks if preload is set on any of themjava.util.List<StoreConfiguration>stores()java.util.List<ConfigurationInfo>subElements()java.lang.StringtoString()booleanusingAsyncStore()booleanusingSegmentedStore()Returns if any store isStoreConfiguration.segmented()booleanusingStores()
-
-
-
Field Detail
-
PASSIVATION
public static final AttributeDefinition<java.lang.Boolean> PASSIVATION
-
AVAILABILITY_INTERVAL
public static final AttributeDefinition<java.lang.Integer> AVAILABILITY_INTERVAL
-
CONNECTION_ATTEMPTS
public static final AttributeDefinition<java.lang.Integer> CONNECTION_ATTEMPTS
-
CONNECTION_INTERVAL
public static final AttributeDefinition<java.lang.Integer> CONNECTION_INTERVAL
-
-
Method Detail
-
getElementDefinition
public ElementDefinition getElementDefinition()
- Specified by:
getElementDefinitionin interfaceBaseConfigurationInfo- Returns:
- the
ElementDefinitionof the configuration.
-
passivation
public boolean passivation()
If true, data is only written to the cache store when it is evicted from memory, a phenomenon known as 'passivation'. Next time the data is requested, it will be 'activated' which means that data will be brought back to memory and removed from the persistent store. This gives you the ability to 'overflow' to disk, similar to swapping in an operating system.
If false, the cache store contains a copy of the contents in memory, so writes to cache result in cache store writes. This essentially gives you a 'write-through' configuration.
-
availabilityInterval
public int availabilityInterval()
-
connectionAttempts
public int connectionAttempts()
-
connectionInterval
public int connectionInterval()
-
stores
public java.util.List<StoreConfiguration> stores()
-
fetchPersistentState
public java.lang.Boolean fetchPersistentState()
Loops through all individual cache loader configs and checks if fetchPersistentState is set on any of them
-
preload
public java.lang.Boolean preload()
Loops through all individual cache loader configs and checks if preload is set on any of them
-
usingStores
public boolean usingStores()
-
usingAsyncStore
public boolean usingAsyncStore()
-
usingSegmentedStore
public boolean usingSegmentedStore()
Returns if any store isStoreConfiguration.segmented()- Returns:
- true if any configured store is segmented, otherwise false
-
attributes
public AttributeSet attributes()
- Specified by:
attributesin interfaceBaseConfigurationInfo- Returns:
- the
AttributeSetdeclared by the configuration.
-
subElements
public java.util.List<ConfigurationInfo> subElements()
- Specified by:
subElementsin interfaceConfigurationInfo- Returns:
- the list of sub elements.
-
toString
public java.lang.String toString()
- Overrides:
toStringin classjava.lang.Object
-
equals
public boolean equals(java.lang.Object obj)
- Overrides:
equalsin classjava.lang.Object
-
hashCode
public int hashCode()
- Overrides:
hashCodein classjava.lang.Object
-
-