Search in sources :

Example 16 with WanCustomPublisherConfig

use of com.hazelcast.config.WanCustomPublisherConfig in project hazelcast by hazelcast.

the class WanCustomPublisherConfigDTOTest method testDefault.

@Test
public void testDefault() {
    WanCustomPublisherConfig expected = new WanCustomPublisherConfig();
    WanCustomPublisherConfig actual = cloneThroughJson(expected);
    assertTrue("Expected: " + expected + ", got:" + actual, WAN_PUBLISHER_CONFIG_CHECKER.check(expected, actual));
}
Also used : WanCustomPublisherConfig(com.hazelcast.config.WanCustomPublisherConfig) ParallelJVMTest(com.hazelcast.test.annotation.ParallelJVMTest) QuickTest(com.hazelcast.test.annotation.QuickTest) Test(org.junit.Test)

Example 17 with WanCustomPublisherConfig

use of com.hazelcast.config.WanCustomPublisherConfig in project hazelcast by hazelcast.

the class WanReplicationConfigurationTest method getConfig.

@Override
protected Config getConfig() {
    if (!isWanReplicationEnabled) {
        return super.getConfig();
    }
    WanCustomPublisherConfig wanCustomPublisherConfig = new WanCustomPublisherConfig().setPublisherId("dummyPublisherId").setClassName(WanDummyPublisher.class.getName());
    WanReplicationConfig wanReplicationConfig = new WanReplicationConfig().setName("dummyWan").addCustomPublisherConfig(wanCustomPublisherConfig);
    WanReplicationRef wanRef = new WanReplicationRef().setName("dummyWan").setRepublishingEnabled(isWanRepublishingEnabled).setMergePolicyClassName(PassThroughMergePolicy.class.getName());
    MapConfig mapConfig = new MapConfig("default").setWanReplicationRef(wanRef);
    return super.getConfig().addWanReplicationConfig(wanReplicationConfig).addMapConfig(mapConfig);
}
Also used : WanReplicationConfig(com.hazelcast.config.WanReplicationConfig) PassThroughMergePolicy(com.hazelcast.spi.merge.PassThroughMergePolicy) WanReplicationRef(com.hazelcast.config.WanReplicationRef) WanCustomPublisherConfig(com.hazelcast.config.WanCustomPublisherConfig) MapConfig(com.hazelcast.config.MapConfig)

Aggregations

WanCustomPublisherConfig (com.hazelcast.config.WanCustomPublisherConfig)17 WanBatchPublisherConfig (com.hazelcast.config.WanBatchPublisherConfig)8 WanReplicationConfig (com.hazelcast.config.WanReplicationConfig)7 WanConsumerConfig (com.hazelcast.config.WanConsumerConfig)6 Test (org.junit.Test)6 MapConfig (com.hazelcast.config.MapConfig)4 QuickTest (com.hazelcast.test.annotation.QuickTest)3 AttributeConfig (com.hazelcast.config.AttributeConfig)2 AwsConfig (com.hazelcast.config.AwsConfig)2 CachePartitionLostListenerConfig (com.hazelcast.config.CachePartitionLostListenerConfig)2 CacheSimpleConfig (com.hazelcast.config.CacheSimpleConfig)2 CacheSimpleEntryListenerConfig (com.hazelcast.config.CacheSimpleEntryListenerConfig)2 CardinalityEstimatorConfig (com.hazelcast.config.CardinalityEstimatorConfig)2 Config (com.hazelcast.config.Config)2 DataPersistenceConfig (com.hazelcast.config.DataPersistenceConfig)2 DiscoveryConfig (com.hazelcast.config.DiscoveryConfig)2 DiscoveryStrategyConfig (com.hazelcast.config.DiscoveryStrategyConfig)2 DiskTierConfig (com.hazelcast.config.DiskTierConfig)2 DurableExecutorConfig (com.hazelcast.config.DurableExecutorConfig)2 EntryListenerConfig (com.hazelcast.config.EntryListenerConfig)2