public class CronWindowProcessor extends WindowProcessor implements org.quartz.Job
WindowProcessor which represent a Window operating based on a cron expression.additionalAttributes, attributeExpressionExecutors, attributeExpressionLength, complexEventPopulater, elementId, inputDefinition, nextProcessor, queryName, streamEventCloner, streamEventClonerHolder| Constructor and Description |
|---|
CronWindowProcessor() |
| Modifier and Type | Method and Description |
|---|---|
Map<String,Object> |
currentState()
Used to collect the serializable state of the processing element, that need to be
persisted for the reconstructing the element to the same state on a different point of time
|
void |
dispatchEvents() |
void |
execute(org.quartz.JobExecutionContext jobExecutionContext) |
protected void |
init(ExpressionExecutor[] attributeExpressionExecutors,
ConfigReader configReader,
boolean outputExpectsExpiredEvents,
SiddhiAppContext siddhiAppContext)
The init method of the WindowProcessor, this method will be called before other methods
|
protected void |
process(ComplexEventChunk<StreamEvent> streamEventChunk,
Processor nextProcessor,
StreamEventCloner streamEventCloner)
The main processing method that will be called upon event arrival
|
void |
restoreState(Map<String,Object> state)
Used to restore serialized state of the processing element, for reconstructing
the element to the same state as if was on a previous point of time.
|
void |
start()
This will be called only once and this can be used to acquire
required resources for the processing element.
|
void |
stop()
This will be called only once and this can be used to release
the acquired resources for processing.
|
init, processEventChunkcloneProcessor, constructStreamEventPopulater, getElementId, getNextProcessor, initProcessor, process, setNextProcessor, setStreamEventCloner, setToLastprotected void init(ExpressionExecutor[] attributeExpressionExecutors, ConfigReader configReader, boolean outputExpectsExpiredEvents, SiddhiAppContext siddhiAppContext)
WindowProcessorinit in class WindowProcessorattributeExpressionExecutors - the executors of each function parametersconfigReader - the config reader of windowoutputExpectsExpiredEvents - is expired event out put or notsiddhiAppContext - the context of the siddhi appprotected void process(ComplexEventChunk<StreamEvent> streamEventChunk, Processor nextProcessor, StreamEventCloner streamEventCloner)
WindowProcessorprocess in class WindowProcessorstreamEventChunk - 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 modificationpublic void start()
EternalReferencedHolderstart in interface EternalReferencedHolderpublic void stop()
EternalReferencedHolderstop in interface EternalReferencedHolderpublic Map<String,Object> currentState()
SnapshotablecurrentState in interface Snapshotablepublic void restoreState(Map<String,Object> state)
SnapshotablerestoreState in interface Snapshotablestate - the stateful objects of the element as an array on
the same order provided by currentState().public void dispatchEvents()
public void execute(org.quartz.JobExecutionContext jobExecutionContext)
throws org.quartz.JobExecutionException
execute in interface org.quartz.Joborg.quartz.JobExecutionExceptionCopyright © 2019 WSO2. All rights reserved.