Class BatchEventProcessExecutor

  • All Implemented Interfaces:
    com.qfs.snl.workflows.process.IEventProcessExecutor, com.qfs.snl.workflows.process.IWorkflowProcessExecutor<com.qfs.snl.data.ISentinelEvent>, com.qfs.snl.workflows.process.IWorkflowProcessExecutor.IExecutableExecutor<com.qfs.snl.data.ISentinelEvent>, com.qfs.snl.workflows.process.IWorkflowProcessExecutor.IExecutorWithType<com.qfs.snl.data.ISentinelEvent>, com.quartetfs.fwk.types.IExtendedPluginValue, Serializable

    @QuartetExtendedPluginValue(intf=com.qfs.snl.workflows.process.IEventProcessExecutor.class,
                                key="EventProcessExecutor")
    public class BatchEventProcessExecutor
    extends com.qfs.snl.workflows.process.impl.EventProcessExecutor
    Implementation of workflow process executor with batch capabilities.

    This implementation is used for event processing, in case we want a better performance when an important number of events are sent to ActiveMonitor application. .

    This uses BatchWorkflowConfig to detect if batch processing applies to the underlying workflow for events.

    Author:
    QuartetFS
    See Also:
    Serialized Form
    • Nested Class Summary

      • Nested classes/interfaces inherited from interface com.qfs.snl.workflows.process.IWorkflowProcessExecutor

        com.qfs.snl.workflows.process.IWorkflowProcessExecutor.IExecutableExecutor<T extends Object>, com.qfs.snl.workflows.process.IWorkflowProcessExecutor.IExecutorWithType<T extends Object>
    • Field Summary

      Fields 
      Modifier and Type Field Description
      protected com.qfs.snl.monitors.IMonitorService monitorService  
      • Fields inherited from class com.qfs.snl.workflows.process.impl.EventProcessExecutor

        PLUGIN_KEY
      • Fields inherited from class com.qfs.snl.workflows.process.impl.AWorkflowProcessExecutor

        actionType, entityType, logger, optional, service
    • Constructor Summary

      Constructors 
      Constructor Description
      BatchEventProcessExecutor​(com.qfs.snl.workflows.IWorkflowService service)
      Constructor.
    • Method Summary

      All Methods Instance Methods Concrete Methods 
      Modifier and Type Method Description
      List<com.qfs.snl.workflows.IWorkflowProcess> forEntities​(List<? extends com.qfs.snl.data.ISentinelEvent> entities, BiFunction<com.qfs.snl.data.ISentinelEvent,​com.qfs.snl.workflows.IWorkflowPayload,​com.qfs.snl.workflows.IWorkflowPayload> payloadBuilder)  
      void setMonitorService​(com.qfs.snl.monitors.IMonitorService monitorService)
      Sets the monitor service for processing.
      • Methods inherited from class com.qfs.snl.workflows.process.impl.EventProcessExecutor

        executeFor, getEntityId, getType
      • Methods inherited from class com.qfs.snl.workflows.process.impl.AWorkflowProcessExecutor

        asBuilder, buildPayload, execute, executeOptionally, forEntity, forType, getEntityConfiguration, getWorkflowSchema, resolveAction
      • Methods inherited from interface com.qfs.snl.workflows.process.IWorkflowProcessExecutor

        forType
    • Field Detail

      • monitorService

        protected transient com.qfs.snl.monitors.IMonitorService monitorService
    • Constructor Detail

      • BatchEventProcessExecutor

        public BatchEventProcessExecutor​(com.qfs.snl.workflows.IWorkflowService service)
        Constructor.
        Parameters:
        service - workflow service to use
    • Method Detail

      • setMonitorService

        public void setMonitorService​(com.qfs.snl.monitors.IMonitorService monitorService)
        Sets the monitor service for processing.
        Parameters:
        monitorService - service to use to work with monitors.
      • forEntities

        public List<com.qfs.snl.workflows.IWorkflowProcess> forEntities​(List<? extends com.qfs.snl.data.ISentinelEvent> entities,
                                                                        BiFunction<com.qfs.snl.data.ISentinelEvent,​com.qfs.snl.workflows.IWorkflowPayload,​com.qfs.snl.workflows.IWorkflowPayload> payloadBuilder)
        Specified by:
        forEntities in interface com.qfs.snl.workflows.process.IWorkflowProcessExecutor.IExecutableExecutor<com.qfs.snl.data.ISentinelEvent>
        Overrides:
        forEntities in class com.qfs.snl.workflows.process.impl.AWorkflowProcessExecutor<com.qfs.snl.data.ISentinelEvent>