public abstract class FileTailingMessageProducerSupport extends MessageProducerSupport implements ApplicationEventPublisherAware
| Modifier and Type | Class and Description |
|---|---|
static class |
FileTailingMessageProducerSupport.FileTailingEvent |
lifecycleCondition, lifecycleLocklogger| Constructor and Description |
|---|
FileTailingMessageProducerSupport() |
| Modifier and Type | Method and Description |
|---|---|
String |
getComponentType()
Subclasses may implement this method to provide component type information.
|
protected File |
getFile() |
protected long |
getMissingFileDelay() |
protected TaskExecutor |
getTaskExecutor() |
protected void |
publish(String message) |
protected void |
send(String line) |
void |
setApplicationEventPublisher(ApplicationEventPublisher applicationEventPublisher) |
void |
setFile(File file)
The name of the file you wish to tail.
|
void |
setTailAttemptsDelay(long tailAttemptsDelay)
The delay in milliseconds between attempts to tail a non-existent file,
or between attempts to execute a process if it fails for any reason.
|
void |
setTaskExecutor(TaskExecutor taskExecutor)
A task executor; default is a
SimpleAsyncTaskExecutor. |
doStart, doStop, getMessagingTemplate, onInit, sendMessage, setErrorChannel, setOutputChannel, setSendTimeout, setShouldTrackdoStop, getPhase, isAutoStartup, isRunning, setAutoStartup, setPhase, setTaskScheduler, start, stop, stopafterPropertiesSet, extractTypeIfPossible, getApplicationContext, getApplicationContextId, getBeanFactory, getChannelResolver, getComponentName, getConversionService, getIntegrationProperties, getIntegrationProperty, getMessageBuilderFactory, getTaskScheduler, setApplicationContext, setBeanFactory, setBeanName, setChannelResolver, setComponentName, setConversionService, setMessageBuilderFactory, toStringclone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, waitgetComponentNamepublic void setApplicationEventPublisher(ApplicationEventPublisher applicationEventPublisher)
setApplicationEventPublisher in interface ApplicationEventPublisherAwarepublic void setFile(File file)
file - The absolute path of the file.protected File getFile()
public void setTaskExecutor(TaskExecutor taskExecutor)
SimpleAsyncTaskExecutor.taskExecutor - The task executor.public void setTailAttemptsDelay(long tailAttemptsDelay)
tailAttemptsDelay - the delay.protected long getMissingFileDelay()
protected TaskExecutor getTaskExecutor()
public String getComponentType()
IntegrationObjectSupportgetComponentType in interface NamedComponentgetComponentType in class IntegrationObjectSupportprotected void send(String line)
protected void publish(String message)