public class TcpNetClientConnectionFactory extends AbstractClientConnectionFactory
TcpNetConnections.DEFAULT_REPLY_TIMEOUT, lifecycleMonitor| Constructor and Description |
|---|
TcpNetClientConnectionFactory(java.lang.String host,
int port)
Creates a TcpNetClientConnectionFactory for connections to the host and port.
|
| Modifier and Type | Method and Description |
|---|---|
protected TcpConnectionSupport |
buildNewConnection() |
protected java.net.Socket |
createSocket(java.lang.String host,
int port)
Create a new
Socket. |
protected TcpSocketFactorySupport |
getTcpSocketFactorySupport() |
void |
setTcpNetConnectionSupport(TcpNetConnectionSupport connectionSupport)
Set the
TcpNetConnectionSupport to use to create connection objects. |
void |
setTcpSocketFactorySupport(TcpSocketFactorySupport tcpSocketFactorySupport) |
void |
start() |
enableManualListenerRegistration, forceClose, getConnection, getTheConnection, initializeConnection, obtainConnection, obtainNewConnection, obtainSharedConnection, setTheConnectionaddConnection, checkActive, closeConnection, delayRead, doAccept, getApplicationEventPublisher, getDelayedReads, getDeserializer, getHost, getListener, getMapper, getOpenConnectionIds, getPort, getReadDelay, getSender, getSerializer, getSoLinger, getSoReceiveBufferSize, getSoSendBufferSize, getSoTimeout, getSoTrafficClass, getSslHandshakeTimeout, getTaskExecutor, getTcpSocketSupport, harvestClosedConnections, isActive, isLookupHost, isRunning, isSingleUse, isSoKeepAlive, isSoTcpNoDelay, onInit, processNioSelections, registerListener, registerSender, setActive, setApplicationEventPublisher, setDeserializer, setHost, setInterceptorFactoryChain, setLeaveOpen, setLookupHost, setMapper, setNioHarvestInterval, setPort, setReadDelay, setSerializer, setSingleUse, setSocketAttributes, setSoKeepAlive, setSoLinger, setSoReceiveBufferSize, setSoSendBufferSize, setSoTcpNoDelay, setSoTimeout, setSoTrafficClass, setSslHandshakeTimeout, setTaskExecutor, setTcpSocketSupport, stop, toString, wrapConnectionafterPropertiesSet, extractTypeIfPossible, getApplicationContext, getApplicationContextId, getBeanFactory, getChannelResolver, getComponentName, getComponentType, getConversionService, getExpression, getIntegrationProperties, getIntegrationProperty, getMessageBuilderFactory, getTaskScheduler, isInitialized, setApplicationContext, setBeanFactory, setBeanName, setChannelResolver, setComponentName, setConversionService, setMessageBuilderFactory, setPrimaryExpression, setTaskSchedulerpublic TcpNetClientConnectionFactory(java.lang.String host,
int port)
host - the hostport - the portprotected TcpConnectionSupport buildNewConnection() throws java.io.IOException, java.net.SocketException, java.lang.Exception
buildNewConnection in class AbstractClientConnectionFactoryjava.io.IOExceptionjava.net.SocketExceptionjava.lang.Exceptionpublic void setTcpNetConnectionSupport(TcpNetConnectionSupport connectionSupport)
TcpNetConnectionSupport to use to create connection objects.connectionSupport - the connection support.public void start()
start in interface org.springframework.context.Lifecyclestart in class AbstractConnectionFactoryprotected java.net.Socket createSocket(java.lang.String host,
int port)
throws java.io.IOException
Socket. This default implementation uses the default
SocketFactory. Override to use some other mechanismhost - The host.port - The port.java.io.IOException - Any IOException.protected TcpSocketFactorySupport getTcpSocketFactorySupport()
public void setTcpSocketFactorySupport(TcpSocketFactorySupport tcpSocketFactorySupport)