Class SitesConfiguration
- java.lang.Object
-
- org.infinispan.commons.configuration.attributes.ConfigurationElement<SitesConfiguration>
-
- org.infinispan.configuration.cache.SitesConfiguration
-
- All Implemented Interfaces:
org.infinispan.commons.configuration.attributes.Matchable<SitesConfiguration>
,org.infinispan.commons.configuration.attributes.Updatable<SitesConfiguration>
public class SitesConfiguration extends org.infinispan.commons.configuration.attributes.ConfigurationElement<SitesConfiguration>
- Since:
- 5.2
- Author:
- Mircea.Markus@jboss.com
-
-
Field Summary
Fields Modifier and Type Field Description static org.infinispan.commons.configuration.attributes.AttributeDefinition<Boolean>
DISABLE_BACKUPS
static org.infinispan.commons.configuration.attributes.AttributeDefinition<Set<String>>
IN_USE_BACKUP_SITES
static org.infinispan.commons.configuration.attributes.AttributeDefinition<Long>
MAX_CLEANUP_DELAY
static org.infinispan.commons.configuration.attributes.AttributeDefinition<XSiteEntryMergePolicy>
MERGE_POLICY
static org.infinispan.commons.configuration.attributes.AttributeDefinition<Integer>
TOMBSTONE_MAP_SIZE
-
Constructor Summary
Constructors Constructor Description SitesConfiguration(org.infinispan.commons.configuration.attributes.AttributeSet attributes, List<BackupConfiguration> allBackups, BackupForConfiguration backupFor)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description List<BackupConfiguration>
allBackups()
Returns the list of all sites where this cache might back up its data.Stream<BackupConfiguration>
asyncBackupsStream()
BackupForConfiguration
backupFor()
boolean
disableBackups()
Returns true if this cache won't backup its data remotely.List<BackupConfiguration>
enabledBackups()
Returns the list ofBackupConfiguration
that haveBackupConfiguration.enabled()
== true.Stream<BackupConfiguration>
enabledBackupStream()
BackupFailurePolicy
getFailurePolicy(String siteName)
boolean
hasAsyncEnabledBackups()
boolean
hasEnabledBackups()
boolean
hasInUseBackup(String siteName)
boolean
hasSyncEnabledBackups()
Set<String>
inUseBackupSites()
long
maxTombstoneCleanupDelay()
XSiteEntryMergePolicy<?,?>
mergePolicy()
Stream<BackupConfiguration>
syncBackupsStream()
int
tombstoneMapSize()
-
-
-
Field Detail
-
DISABLE_BACKUPS
public static final org.infinispan.commons.configuration.attributes.AttributeDefinition<Boolean> DISABLE_BACKUPS
-
IN_USE_BACKUP_SITES
public static final org.infinispan.commons.configuration.attributes.AttributeDefinition<Set<String>> IN_USE_BACKUP_SITES
-
MERGE_POLICY
public static final org.infinispan.commons.configuration.attributes.AttributeDefinition<XSiteEntryMergePolicy> MERGE_POLICY
-
MAX_CLEANUP_DELAY
public static final org.infinispan.commons.configuration.attributes.AttributeDefinition<Long> MAX_CLEANUP_DELAY
-
TOMBSTONE_MAP_SIZE
public static final org.infinispan.commons.configuration.attributes.AttributeDefinition<Integer> TOMBSTONE_MAP_SIZE
-
-
Constructor Detail
-
SitesConfiguration
public SitesConfiguration(org.infinispan.commons.configuration.attributes.AttributeSet attributes, List<BackupConfiguration> allBackups, BackupForConfiguration backupFor)
-
-
Method Detail
-
disableBackups
public boolean disableBackups()
Returns true if this cache won't backup its data remotely. It would still accept other sites backing up data on this site.
-
allBackups
public List<BackupConfiguration> allBackups()
Returns the list of all sites where this cache might back up its data. The list of actual sites is defined byinUseBackupSites
.
-
enabledBackups
public List<BackupConfiguration> enabledBackups()
Returns the list ofBackupConfiguration
that haveBackupConfiguration.enabled()
== true.
-
enabledBackupStream
public Stream<BackupConfiguration> enabledBackupStream()
-
backupFor
public BackupForConfiguration backupFor()
- Returns:
- information about caches that backup data into this cache.
-
getFailurePolicy
public BackupFailurePolicy getFailurePolicy(String siteName)
-
hasInUseBackup
public boolean hasInUseBackup(String siteName)
-
hasEnabledBackups
public boolean hasEnabledBackups()
-
hasSyncEnabledBackups
public boolean hasSyncEnabledBackups()
-
syncBackupsStream
public Stream<BackupConfiguration> syncBackupsStream()
-
hasAsyncEnabledBackups
public boolean hasAsyncEnabledBackups()
-
asyncBackupsStream
public Stream<BackupConfiguration> asyncBackupsStream()
-
mergePolicy
public XSiteEntryMergePolicy<?,?> mergePolicy()
- Returns:
- The
XSiteEntryMergePolicy
to resolve conflicts when asynchronous cross-site replication is enabled. - See Also:
SitesConfigurationBuilder.mergePolicy(XSiteEntryMergePolicy)
-
maxTombstoneCleanupDelay
public long maxTombstoneCleanupDelay()
- Returns:
- The maximum delay, in milliseconds, between which tombstone cleanup tasks run.
-
tombstoneMapSize
public int tombstoneMapSize()
- Returns:
- The target tombstone map size.
-
-