Configuration.tee()
Description
Appends a tee filter to the current pipeline layout.
A tee filter writes input Data to a file.
- INPUT - Any types of Events.
- OUTPUT - Same Events as the input.
This filter resembles what the Unix command tee does. The pathname of the output file is specified in the first parameter. It is expected to be a string or a function that returns a string. Use "-" for writing to the standard output.
When outputting to the standard output, this filter is different from print() in that, the output does not go to the logging system so won't be visible on the Admin GUI.
The content of the output file will be erased before writing. If the output file does not exist yet, it will be created. The directories containing the file are also created if not exist. Make sure the process has required privileges to create and write to the file and the directories.
This filter passes everything down unaltered. It doesn't change anything in the event stream. Only Data events are written to the output file as a continuous byte stream.
Syntax
pipy().pipeline().tee(filename)pipy().pipeline().tee(() => getFilename())
Parameters
tee(filename)
Pathname of the file to write to.
The same Configuration object.