Class PollThor
- All Implemented Interfaces:
AdaptrisComponent,AdaptrisMessageProducer,AdaptrisMessageSender,AdaptrisMessageWorker,ComponentLifecycle,ComponentLifecycleExtension,MessageEventGenerator
The use case for this service is, if there is a long-running Job on Thor (scheduled or otherwise) that creates a logical file; you need to wait for the existence of this file before carrying on with the rest of the adapter workflow (usually despraying the logical file that was created).
Note that although this is an implementation of AdaptrisMessageProducerImp the
AdaptrisMessageProducer#produce() methods will throw a
UnsupportedOperationException. It should be used as part of a StandaloneRequestor
where the SingleFileRequest.getLogicalFilename() returns the logical filename of the file that you wish to
retrieve.
In the adapter configuration file this class is aliased as poll-thor which is the preferred alternative to the fully qualified classname when building your configuration.
-
Field Summary
Fields inherited from class com.adaptris.hpcc.DfuPlusWrapper
executorFields inherited from class com.adaptris.core.AdaptrisMessageWorkerImp
log -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionprotected AdaptrisMessagedoRequest(AdaptrisMessage msg, String endpoint, long timeoutMs) voidstop()Methods inherited from class com.adaptris.hpcc.SingleFileRequest
endpoint, getLogicalFilename, prepare, setLogicalFilenameMethods inherited from class com.adaptris.hpcc.RequestOnlyImpl
doProduceMethods inherited from class com.adaptris.hpcc.DfuPlusWrapper
calculateWait, close, execute, executeInternal, generateExceptionMessage, getMaxWait, getMonitorInterval, init, maxWaitMs, monitorIntervalMs, produce, request, request, setMaxWait, setMonitorInterval, startMethods inherited from class com.adaptris.core.AdaptrisMessageProducerImp
createNameMethods inherited from class com.adaptris.core.AdaptrisMessageWorkerImp
createQualifier, decode, encode, getEncoder, getIsTrackingEndpoint, getMessageFactory, getUniqueId, handleConnectionException, isTrackingEndpoint, registerConnection, registerEncoderMessageFactory, retrieveConnection, setEncoder, setIsTrackingEndpoint, setMessageFactory, setUniqueId, withMessageFactory, withUniqueIDMethods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface com.adaptris.core.AdaptrisComponent
getUniqueIdMethods inherited from interface com.adaptris.core.AdaptrisMessageWorker
decode, encode, getEncoder, getMessageFactory, handleConnectionException, registerConnection, retrieveConnection, setEncoder, setMessageFactoryMethods inherited from interface com.adaptris.core.MessageEventGenerator
createQualifier, isTrackingEndpoint
-
Constructor Details
-
PollThor
public PollThor()
-
-
Method Details
-
stop
public void stop()- Specified by:
stopin interfaceComponentLifecycle- Overrides:
stopin classDfuPlusWrapper
-
doRequest
protected AdaptrisMessage doRequest(AdaptrisMessage msg, String endpoint, long timeoutMs) throws ProduceException - Specified by:
doRequestin classDfuPlusWrapper- Throws:
ProduceException
-