Developer Guide
Also available as:
PDF
loading table of contents...
Performing the Work

When a Processor has work to do, it is scheduled to do so by having its onTrigger method called by the framework. The method takes two arguments: a ProcessContext and a ProcessSession. The first step in the onTrigger method is often to obtain a FlowFile on which the work is to be performed by calling one of the get methods on the ProcessSession. For Processors that ingest data into NiFi from external sources, this step is skipped. The Processor is then free to examine FlowFile attributes; add, remove, or modify attributes; read or modify FlowFile content; and transfer FlowFiles to the appropriate Relationships.