Class CronWindowProcessor
- java.lang.Object
-
- io.siddhi.core.query.processor.stream.AbstractStreamProcessor<S>
-
- io.siddhi.core.query.processor.stream.window.WindowProcessor<S>
-
- io.siddhi.core.query.processor.stream.window.BatchingWindowProcessor<io.siddhi.core.query.processor.stream.window.CronWindowProcessor.WindowState>
-
- io.siddhi.core.query.processor.stream.window.CronWindowProcessor
-
- All Implemented Interfaces:
Processor,ExternalReferencedHolder,org.quartz.Job
public class CronWindowProcessor extends BatchingWindowProcessor<io.siddhi.core.query.processor.stream.window.CronWindowProcessor.WindowState> implements org.quartz.Job
Implementation ofWindowProcessorwhich represent a Window operating based on a cron expression.
-
-
Field Summary
-
Fields inherited from class io.siddhi.core.query.processor.stream.AbstractStreamProcessor
attributeExpressionExecutors, attributeExpressionLength, complexEventPopulater, inputDefinition, metaStreamEvent, nextProcessor, siddhiQueryContext, stateHolder
-
-
Constructor Summary
Constructors Constructor Description CronWindowProcessor()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description voiddispatchEvents()voidexecute(org.quartz.JobExecutionContext jobExecutionContext)protected StateFactory<io.siddhi.core.query.processor.stream.window.CronWindowProcessor.WindowState>init(ExpressionExecutor[] attributeExpressionExecutors, ConfigReader configReader, StreamEventClonerHolder streamEventClonerHolder, boolean outputExpectsExpiredEvents, boolean findToBeExecuted, SiddhiQueryContext siddhiQueryContext)The init method of the WindowProcessor, this method will be called before other methodsprotected voidprocess(ComplexEventChunk<StreamEvent> streamEventChunk, Processor nextProcessor, StreamEventCloner streamEventCloner, io.siddhi.core.query.processor.stream.window.CronWindowProcessor.WindowState state)The main processing method that will be called upon event arrivalvoidstart()This will be called only once and this can be used to acquire required resources for the processing element.voidstop()This will be called only once and this can be used to release the acquired resources for processing.-
Methods inherited from class io.siddhi.core.query.processor.stream.window.BatchingWindowProcessor
getProcessingMode, init, processEventChunk
-
Methods inherited from class io.siddhi.core.query.processor.stream.window.WindowProcessor
getReturnAttributes
-
Methods inherited from class io.siddhi.core.query.processor.stream.AbstractStreamProcessor
constructStreamEventPopulater, getNextProcessor, initProcessor, isStateful, process, process, setNextProcessor, setStreamEventCloner, setToLast
-
-
-
-
Method Detail
-
init
protected StateFactory<io.siddhi.core.query.processor.stream.window.CronWindowProcessor.WindowState> init(ExpressionExecutor[] attributeExpressionExecutors, ConfigReader configReader, StreamEventClonerHolder streamEventClonerHolder, boolean outputExpectsExpiredEvents, boolean findToBeExecuted, SiddhiQueryContext siddhiQueryContext)
Description copied from class:BatchingWindowProcessorThe init method of the WindowProcessor, this method will be called before other methods- Specified by:
initin classBatchingWindowProcessor<io.siddhi.core.query.processor.stream.window.CronWindowProcessor.WindowState>- Parameters:
attributeExpressionExecutors- the executors of each function parametersconfigReader- the config reader of windowstreamEventClonerHolder- stream event cloner holderoutputExpectsExpiredEvents- is expired events sent as outputfindToBeExecuted- find operation will be performedsiddhiQueryContext- the context of the siddhi query
-
process
protected void process(ComplexEventChunk<StreamEvent> streamEventChunk, Processor nextProcessor, StreamEventCloner streamEventCloner, io.siddhi.core.query.processor.stream.window.CronWindowProcessor.WindowState state)
Description copied from class:BatchingWindowProcessorThe main processing method that will be called upon event arrival- Specified by:
processin classBatchingWindowProcessor<io.siddhi.core.query.processor.stream.window.CronWindowProcessor.WindowState>- Parameters:
streamEventChunk- the stream event chunk that need to be processednextProcessor- the next processor to which the success events need to be passedstreamEventCloner- helps to clone the incoming event for local storage or modificationstate- current state of the processor
-
start
public void start()
Description copied from interface:ExternalReferencedHolderThis will be called only once and this can be used to acquire required resources for the processing element. This will be called after initializing the system and before starting to process the events.- Specified by:
startin interfaceExternalReferencedHolder
-
stop
public void stop()
Description copied from interface:ExternalReferencedHolderThis will be called only once and this can be used to release the acquired resources for processing. This will be called before shutting down the system.- Specified by:
stopin interfaceExternalReferencedHolder
-
dispatchEvents
public void dispatchEvents()
-
execute
public void execute(org.quartz.JobExecutionContext jobExecutionContext) throws org.quartz.JobExecutionException- Specified by:
executein interfaceorg.quartz.Job- Throws:
org.quartz.JobExecutionException
-
-