.tcpNoDelay(this.tcpNoDelay) .tcpKeepAlive(this.tcpKeepAlive) .valueSizeEstimate(this.valueSizeEstimate);
.tcpNoDelay(this.tcpNoDelay) .tcpKeepAlive(this.tcpKeepAlive) .valueSizeEstimate(this.valueSizeEstimate);
.valueSizeEstimate(512); return config.build();
private ConfigurationBuilder createRemoteCacheManagerConfigurationBuilder() { ConfigurationBuilder config = new ConfigurationBuilder(); addServers(config); config.balancingStrategy("org.infinispan.server.test.client.hotrod.HotRodTestRequestBalancingStrategy") .forceReturnValues(true) .tcpNoDelay(false) .tcpKeepAlive(true) .marshaller("org.infinispan.server.test.client.hotrod.HotRodTestMarshaller") .asyncExecutorFactory().factoryClass("org.infinispan.server.test.client.hotrod.HotRodTestExecutorFactory") .addExecutorProperty("infinispan.client.hotrod.default_executor_factory.pool_size", "20") .addExecutorProperty("infinispan.client.hotrod.default_executor_factory.queue_size", "200000") .keySizeEstimate(128) .valueSizeEstimate(1024); return config; }
@Test public void testEmptyConfiguration() throws Exception { ConfigurationBuilder confBuilder = new ConfigurationBuilder(); addServers(confBuilder); RemoteCacheManager rcm = new RemoteCacheManager(confBuilder.build()); RemoteCache rc = rcm.getCache(testCache); ConfigurationBuilder builder = new ConfigurationBuilder(); addServers(builder); builder.balancingStrategy("org.infinispan.client.hotrod.impl.transport.tcp.RoundRobinBalancingStrategy") .forceReturnValues(false) .tcpNoDelay(true) .transportFactory("org.infinispan.client.hotrod.impl.transport.tcp.TcpTransportFactory") .marshaller("org.infinispan.commons.marshall.jboss.GenericJBossMarshaller") .asyncExecutorFactory().factoryClass("org.infinispan.client.hotrod.impl.async.DefaultAsyncExecutorFactory") .addExecutorProperty("infinispan.client.hotrod.default_executor_factory.pool_size", "10") .addExecutorProperty("infinispan.client.hotrod.default_executor_factory.queue_size", "100000") .keySizeEstimate(64) .valueSizeEstimate(512); Configuration defaultConf = builder.build(); assertEqualConfiguration(defaultConf, rc); }