Search in sources :

Example 1 with BackupConfiguration

use of org.infinispan.configuration.cache.BackupConfiguration in project wildfly by wildfly.

the class BackupsBuilder method getValue.

@Override
public SitesConfiguration getValue() {
    SitesConfigurationBuilder builder = new ConfigurationBuilder().sites();
    builder.backupFor().read(this.backupFor.getValue());
    builder.disableBackups(this.backups.isEmpty());
    for (Map.Entry<String, BackupConfiguration> backup : this.backups.entrySet()) {
        builder.addBackup().read(backup.getValue());
        builder.addInUseBackupSite(backup.getKey());
    }
    return builder.create();
}
Also used : ConfigurationBuilder(org.infinispan.configuration.cache.ConfigurationBuilder) SitesConfigurationBuilder(org.infinispan.configuration.cache.SitesConfigurationBuilder) BackupConfigurationBuilder(org.infinispan.configuration.cache.BackupConfigurationBuilder) SitesConfigurationBuilder(org.infinispan.configuration.cache.SitesConfigurationBuilder) BackupConfiguration(org.infinispan.configuration.cache.BackupConfiguration) HashMap(java.util.HashMap) Map(java.util.Map)

Aggregations

HashMap (java.util.HashMap)1 Map (java.util.Map)1 BackupConfiguration (org.infinispan.configuration.cache.BackupConfiguration)1 BackupConfigurationBuilder (org.infinispan.configuration.cache.BackupConfigurationBuilder)1 ConfigurationBuilder (org.infinispan.configuration.cache.ConfigurationBuilder)1 SitesConfigurationBuilder (org.infinispan.configuration.cache.SitesConfigurationBuilder)1