Search in sources :

Example 26 with Scheduler

use of org.wso2.siddhi.core.util.Scheduler in project carbon-business-process by wso2.

the class BPMNEngineWaitBeforeShutdownObserver method startingShutdown.

@Override
public void startingShutdown() {
    log.info("Shutting down activiti process engine");
    SubstitutionScheduler scheduler = BPMNServerHolder.getInstance().getSubstitutionScheduler();
    if (scheduler != null) {
        log.info("Shutting down the BPMN Substitution Scheduler");
        scheduler.stop();
    }
    log.info("Beginning to close down the command context");
    if (Context.getCommandContext() != null) {
        Context.getCommandContext().close();
        log.info("Completed the closing of command context");
    }
    ProcessEngines.destroy();
    status = true;
}
Also used : SubstitutionScheduler(org.wso2.carbon.bpmn.people.substitution.scheduler.SubstitutionScheduler)

Aggregations

StreamEventPool (org.wso2.siddhi.core.event.stream.StreamEventPool)13 Scheduler (org.wso2.siddhi.core.util.Scheduler)6 EntryValveProcessor (org.wso2.siddhi.core.query.input.stream.single.EntryValveProcessor)5 ArrayList (java.util.ArrayList)4 MetaStreamEvent (org.wso2.siddhi.core.event.stream.MetaStreamEvent)3 SingleStreamRuntime (org.wso2.siddhi.core.query.input.stream.single.SingleStreamRuntime)3 SubstitutionScheduler (org.wso2.carbon.bpmn.people.substitution.scheduler.SubstitutionScheduler)2 OperationNotSupportedException (org.wso2.siddhi.core.exception.OperationNotSupportedException)2 SiddhiAppCreationException (org.wso2.siddhi.core.exception.SiddhiAppCreationException)2 SchedulingProcessor (org.wso2.siddhi.core.query.processor.SchedulingProcessor)2 WindowProcessor (org.wso2.siddhi.core.query.processor.stream.window.WindowProcessor)2 Attribute (org.wso2.siddhi.query.api.definition.Attribute)2 ThreadFactoryBuilder (com.google.common.util.concurrent.ThreadFactoryBuilder)1 AbstractMap (java.util.AbstractMap)1 HashSet (java.util.HashSet)1 Set (java.util.Set)1 ExecutorService (java.util.concurrent.ExecutorService)1 ThreadFactory (java.util.concurrent.ThreadFactory)1 ReentrantLock (java.util.concurrent.locks.ReentrantLock)1 SimpleSchedulerConfig (org.wso2.carbon.bpel.config.SimpleSchedulerConfig)1