/** * @return String details */ @Override public String toString() { StringBuilder buf = new StringBuilder(super.toString()); buf.append( "\n servicePort = [" + this.getServicePort() + "]" ); buf.append( "\n allowClusterGet = [" + this.isAllowClusterGet() + "]" ); buf.append( "\n configFileName = [" + this.getConfigFileName() + "]" ); buf.append( "\n rmiSocketFactoryTimeoutMillis = [" + this.getRmiSocketFactoryTimeoutMillis() + "]" ); buf.append( "\n useRegistryKeepAlive = [" + this.isUseRegistryKeepAlive() + "]" ); buf.append( "\n registryKeepAliveDelayMillis = [" + this.getRegistryKeepAliveDelayMillis() + "]" ); buf.append( "\n eventQueueType = [" + this.getEventQueueType() + "]" ); buf.append( "\n eventQueuePoolName = [" + this.getEventQueuePoolName() + "]" ); return buf.toString(); } }
/** * @return String details */ @Override public String toString() { StringBuilder buf = new StringBuilder(super.toString()); buf.append( "\n servicePort = [" + this.getServicePort() + "]" ); buf.append( "\n allowClusterGet = [" + this.isAllowClusterGet() + "]" ); buf.append( "\n configFileName = [" + this.getConfigFileName() + "]" ); buf.append( "\n rmiSocketFactoryTimeoutMillis = [" + this.getRmiSocketFactoryTimeoutMillis() + "]" ); buf.append( "\n startRegistry = [" + this.isStartRegistry() + "]" ); buf.append( "\n useRegistryKeepAlive = [" + this.isUseRegistryKeepAlive() + "]" ); buf.append( "\n registryKeepAliveDelayMillis = [" + this.getRegistryKeepAliveDelayMillis() + "]" ); buf.append( "\n eventQueueType = [" + this.getEventQueueType() + "]" ); buf.append( "\n eventQueuePoolName = [" + this.getEventQueuePoolName() + "]" ); return buf.toString(); } }
/** verify that we get the timeout value */ public void testConfigureRemoteCacheServerAttributes_timeoutPresent() { // SETUP int timeout = 123245; Properties props = new Properties(); props.put( IRemoteCacheConstants.SOCKET_TIMEOUT_MILLIS, String.valueOf( timeout ) ); // DO WORK RemoteCacheServerAttributes result = RemoteCacheServerFactory.configureRemoteCacheServerAttributes( props ); // VERIFY assertEquals( "Wrong timeout", timeout, result.getRmiSocketFactoryTimeoutMillis() ); }
/** verify that we get the registryKeepAliveDelayMillis value */ public void testConfigureRemoteCacheServerAttributes_rmiSocketFactoryTimeoutMillisPresent() { // SETUP int rmiSocketFactoryTimeoutMillis = 123245; Properties props = new Properties(); props.put( IRemoteCacheConstants.CACHE_SERVER_ATTRIBUTES_PROPERTY_PREFIX + ".rmiSocketFactoryTimeoutMillis", String.valueOf( rmiSocketFactoryTimeoutMillis ) ); // DO WORK RemoteCacheServerAttributes result = RemoteCacheServerFactory.configureRemoteCacheServerAttributes( props ); // VERIFY assertEquals( "Wrong rmiSocketFactoryTimeoutMillis", rmiSocketFactoryTimeoutMillis, result.getRmiSocketFactoryTimeoutMillis() ); }
/** verify that we get the timeout value */ public void testConfigureRemoteCacheServerAttributes_timeoutPresent() { // SETUP int timeout = 123245; Properties props = new Properties(); props.put( IRemoteCacheConstants.SOCKET_TIMEOUT_MILLIS, String.valueOf( timeout ) ); // DO WORK RemoteCacheServerAttributes result = RemoteCacheServerFactory.configureRemoteCacheServerAttributes( props ); // VERIFY assertEquals( "Wrong timeout", timeout, result.getRmiSocketFactoryTimeoutMillis() ); }
/** verify that we get the registryKeepAliveDelayMillis value */ public void testConfigureRemoteCacheServerAttributes_rmiSocketFactoryTimeoutMillisPresent() { // SETUP int rmiSocketFactoryTimeoutMillis = 123245; Properties props = new Properties(); props.put( IRemoteCacheConstants.CACHE_SERVER_ATTRIBUTES_PROPERTY_PREFIX + ".rmiSocketFactoryTimeoutMillis", String.valueOf( rmiSocketFactoryTimeoutMillis ) ); // DO WORK RemoteCacheServerAttributes result = RemoteCacheServerFactory.configureRemoteCacheServerAttributes( props ); // VERIFY assertEquals( "Wrong rmiSocketFactoryTimeoutMillis", rmiSocketFactoryTimeoutMillis, result.getRmiSocketFactoryTimeoutMillis() ); }
/** verify that we get the timeout value */ public void testConfigureRemoteCacheServerAttributes_timeoutNotPresent() { // SETUP Properties props = new Properties(); // DO WORK RemoteCacheServerAttributes result = RemoteCacheServerFactory.configureRemoteCacheServerAttributes( props ); // VERIFY assertEquals( "Wrong timeout", ICommonRemoteCacheAttributes.DEFAULT_RMI_SOCKET_FACTORY_TIMEOUT_MILLIS, result.getRmiSocketFactoryTimeoutMillis() ); }
/** verify that we get the timeout value */ public void testConfigureRemoteCacheServerAttributes_timeoutNotPresent() { // SETUP Properties props = new Properties(); // DO WORK RemoteCacheServerAttributes result = RemoteCacheServerFactory.configureRemoteCacheServerAttributes( props ); // VERIFY assertEquals( "Wrong timeout", ICommonRemoteCacheAttributes.DEFAULT_RMI_SOCKET_FACTORY_TIMEOUT_MILLIS, result.getRmiSocketFactoryTimeoutMillis() ); }
RemoteUtils.configureGlobalCustomSocketFactory( rcsa.getRmiSocketFactoryTimeoutMillis() );
RemoteUtils.configureGlobalCustomSocketFactory( rcsa.getRmiSocketFactoryTimeoutMillis() );