Class AbstractProcessor

All Implemented Interfaces:
ConfigurableComponent, Processor

public abstract class AbstractProcessor extends AbstractSessionFactoryProcessor
  • Constructor Details

    • AbstractProcessor

      public AbstractProcessor()
  • Method Details

    • onTrigger

      public final void onTrigger(ProcessContext context, ProcessSessionFactory sessionFactory) throws ProcessException
      Description copied from interface: Processor

      The method called when this processor is triggered to operate by the controller. In the absence of the TriggerSerially annotation, this method may be called concurrently from different threads. When this method is called depends on how this processor is configured within a controller to be triggered (timing or event based).

      Parameters:
      context - provides access to convenience methods for obtaining property values, delaying the scheduling of the processor, provides access to Controller Services, etc.
      sessionFactory - provides access to a ProcessSession, which can be used for accessing FlowFiles, etc.
      Throws:
      ProcessException - if processing did not complete normally though indicates the problem is an understood potential outcome of processing. The controller/caller will handle these exceptions gracefully such as logging, etc.. If another type of exception is allowed to propagate the controller may no longer trigger this processor to operate, as this would indicate a probable coding defect.
    • onTrigger

      public abstract void onTrigger(ProcessContext context, ProcessSession session) throws ProcessException
      Throws:
      ProcessException