<tail-f>
Purpose/Function
Stream UNIX-like tail -f
on a file as events. Creates a StreamMonitor to handle the stdout from the asynchronously executed tail -f
process; uses the <stream-progress-action>
to send the file contents as DEBUG events.
Since the task is by nature asynchronous, it registers itself in the global environment under the task name it is given. To stop it, pass this variable to the <stop> task as the stoppable attribute.
Attributes
NAME |
TYPE |
DEFAULT VALUE |
DESCRIPTION |
---|---|---|---|
file |
|
(required) |
file on which to run |
topic |
|
(default producer topic) |
set the event TOPIC to this |
Elements
None.
ReturnValues
None.
Examples
<ogrescript> <tail-f taskName="file://TailOfTest.txt" file="/tmp/test.txt" topic="TROLL"/> <stop delay="30000" stoppable="${file://TailOfTest.txt}"/> </ogrescript>