Class OFSocketTransportImpl
java.lang.Object
org.apache.uima.collection.impl.cpm.container.deployer.socket.OFSocketTransportImpl
- All Implemented Interfaces:
SocketTransport
The Class OFSocketTransportImpl.
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionCreates a socket connection to a given endpoint.getName()
Returns transport identifier.getProcessingResourceMetaData
(Socket aSocket) Returns metadata associated with the fenced CasProcessor.Invokes fenced CasProcessor.
-
Constructor Details
-
OFSocketTransportImpl
public OFSocketTransportImpl()Instantiates a new OF socket transport impl.
-
-
Method Details
-
getName
Description copied from interface:SocketTransport
Returns transport identifier.- Specified by:
getName
in interfaceSocketTransport
- Returns:
- - String uniquely identifying the transport.
-
connect
Description copied from interface:SocketTransport
Creates a socket connection to a given endpoint. This method blocks until all Connections are resolved or an error occurs.- Specified by:
connect
in interfaceSocketTransport
- Parameters:
aURI
- URI containing service endpoint info: host & portaTimeout
- max time in millis to wait for response- Returns:
- Socket bound to a given endpoint
- Throws:
SocketException
- Failed to connect
-
process
Description copied from interface:SocketTransport
Invokes fenced CasProcessor.- Specified by:
process
in interfaceSocketTransport
- Parameters:
aSocket
- - Socket bound to fenced CasProcessoraCas
- - CAS to be sent to the CasProcessor for analysis- Returns:
- - CAS - CAS returned from the fenced CasProcessor
- Throws:
SocketTimeoutException
- the socket timeout exceptionSocketException
- the socket exception
-
getProcessingResourceMetaData
public ProcessingResourceMetaData getProcessingResourceMetaData(Socket aSocket) throws SocketException Description copied from interface:SocketTransport
Returns metadata associated with the fenced CasProcessor.- Specified by:
getProcessingResourceMetaData
in interfaceSocketTransport
- Parameters:
aSocket
- - socket to the fenced CasProcessor- Returns:
- - metadata
- Throws:
SocketException
- passthru
-