Class TimeoutConfigurableRMISocketFactory
java.lang.Object
java.rmi.server.RMISocketFactory
org.apache.commons.jcs3.auxiliary.remote.server.TimeoutConfigurableRMISocketFactory
- All Implemented Interfaces:
Serializable,RMIClientSocketFactory,RMIServerSocketFactory
This can be injected into the remote cache server as follows:
jcs.remotecache.customrmisocketfactory=org.apache.commons.jcs3.auxiliary.remote.server.TimeoutConfigurableRMISocketFactory jcs.remotecache.customrmisocketfactory.readTimeout=5000 jcs.remotecache.customrmisocketfactory.openTimeout=5000
- See Also:
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptioncreateServerSocket(int port) createSocket(String host, int port) intintvoidsetOpenTimeout(int openTimeout) voidsetReadTimeout(int readTimeout) Methods inherited from class java.rmi.server.RMISocketFactory
getDefaultSocketFactory, getFailureHandler, getSocketFactory, setFailureHandler, setSocketFactory
-
Constructor Details
-
TimeoutConfigurableRMISocketFactory
public TimeoutConfigurableRMISocketFactory()
-
-
Method Details
-
createServerSocket
- Specified by:
createServerSocketin interfaceRMIServerSocketFactory- Specified by:
createServerSocketin classRMISocketFactory- Parameters:
port-- Returns:
- ServerSocket
- Throws:
IOException
-
createSocket
- Specified by:
createSocketin interfaceRMIClientSocketFactory- Specified by:
createSocketin classRMISocketFactory- Parameters:
host-port-- Returns:
- Socket
- Throws:
IOException
-
setReadTimeout
- Parameters:
readTimeout- the readTimeout to set
-
getReadTimeout
- Returns:
- the readTimeout
-
setOpenTimeout
- Parameters:
openTimeout- the openTimeout to set
-
getOpenTimeout
- Returns:
- the openTimeout
-