public EPEventServiceImpl createEPRuntime(EPServicesContext services, AtomicBoolean serviceStatusProvider) { return new EPEventServiceImpl(services); }
public void advanceTimeSpan(long targetTime) { advanceTimeSpanInternal(targetTime, null); }
private void processThreadWorkQueueFront(DualWorkQueue queues) { Object item; while ((item = queues.getFrontQueue().poll()) != null) { if (item instanceof InsertIntoLatchSpin) { processThreadWorkQueueLatchedSpin((InsertIntoLatchSpin) item); } else if (item instanceof InsertIntoLatchWait) { processThreadWorkQueueLatchedWait((InsertIntoLatchWait) item); } else { processThreadWorkQueueUnlatched(item); } boolean haveDispatched = services.getNamedWindowDispatchService().dispatch(); if (haveDispatched) { dispatch(); } } }
public void run() { try { EPEventServiceImpl.processStatementScheduleMultiple(handle, callbackObject, services); // Let listeners know of results runtime.dispatch(); // Work off the event queue if any events accumulated in there via a route() runtime.processThreadWorkQueue(); } catch (RuntimeException e) { log.error("Unexpected error processing multiple timer execution: " + e.getMessage(), e); } } }
public void run() { try { EPEventServiceImpl.processStatementScheduleSingle(handleCallback, services); runtime.dispatch(); runtime.processThreadWorkQueue(); } catch (RuntimeException e) { log.error("Unexpected error processing timer execution: " + e.getMessage(), e); } } }
public void run() { try { epRuntime.processStatementFilterMultiple(handle, callbackList, theEvent, filterVersion, 0); epRuntime.dispatch(); epRuntime.processThreadWorkQueue(); } catch (RuntimeException e) { log.error("Unexpected error processing multiple route execution: " + e.getMessage(), e); } }
public void run() { try { EventBean eventBean = runtime.getServices().getEventTypeResolvingBeanFactory().adapterForMap(map, eventTypeName); runtime.processWrappedEvent(eventBean); } catch (RuntimeException e) { runtime.getServices().getExceptionHandlingService().handleInboundPoolException(runtime.getRuntimeURI(), e, map); log.error("Unexpected error processing Map event: " + e.getMessage(), e); } } }
public void advanceTime(long time) { if (InstrumentationHelper.ENABLED) { InstrumentationHelper.get().qStimulantTime(services.getSchedulingService().getTime(), time, time, false, null, services.getRuntimeURI()); } services.getSchedulingService().setTime(time); services.getMetricReportingService().processTimeEvent(time); processSchedule(time); // Let listeners know of results dispatch(); // Work off the event queue if any events accumulated in there via a route() processThreadWorkQueue(); if (InstrumentationHelper.ENABLED) { InstrumentationHelper.get().aStimulantTime(); } }
public void run() { try { epRuntime.processStatementFilterSingle(handleCallback.getAgentInstanceHandle(), handleCallback, theEvent, filterVersion, 0); epRuntime.dispatch(); epRuntime.processThreadWorkQueue(); } catch (RuntimeException e) { log.error("Unexpected error processing route execution: " + e.getMessage(), e); } }
private void processThreadWorkQueueUnlatched(Object item) { EventBean eventBean; if (item instanceof EventBean) { eventBean = (EventBean) item; } else { throw new IllegalStateException("Unexpected item type " + item + " in queue"); } if (InstrumentationHelper.ENABLED) { InstrumentationHelper.get().qEvent(eventBean, services.getRuntimeURI(), false); } services.getEventProcessingRWLock().acquireReadLock(); try { processMatches(eventBean); } catch (RuntimeException ex) { matchesArrayThreadLocal.get().clear(); throw ex; } finally { services.getEventProcessingRWLock().releaseReadLock(); if (InstrumentationHelper.ENABLED) { InstrumentationHelper.get().aEvent(); } } dispatch(); }
processMatches(eventBean); } catch (RuntimeException ex) { matchesArrayThreadLocal.get().clear(); dispatch(); processThreadWorkQueue();
public void clearCaches() { initThreadLocals(); }
handleFilterFault(handle, theEvent, filterFaultCount);
public void timerCallback() { long msec = services.getTimeSourceService().getTimeMillis(); if ((ExecutionPathDebugLog.isDebugEnabled) && (log.isDebugEnabled() && (ExecutionPathDebugLog.isTimerDebugEnabled))) { log.debug(".timerCallback Evaluating scheduled callbacks, time is " + msec); } advanceTime(msec); }
public Map<DeploymentIdNamePair, Long> getStatementNearestSchedules() { return getStatementNearestSchedulesInternal(services.getSchedulingService(), services.getStatementLifecycleService()); }
public void run() { try { EventBean eventBean = runtime.getServices().getEventTypeResolvingBeanFactory().adapterForXMLDOM(theEvent, eventTypeName); runtime.processWrappedEvent(eventBean); } catch (RuntimeException e) { runtime.getServices().getExceptionHandlingService().handleInboundPoolException(runtime.getRuntimeURI(), e, theEvent); log.error("Unexpected error processing DOM event: " + e.getMessage(), e); } } }
processSchedule(currentTime); dispatch(); processThreadWorkQueue();
private void processThreadWorkQueueLatchedSpin(InsertIntoLatchSpin insertIntoLatch) { // wait for the latch to complete EventBean eventBean = insertIntoLatch.await(); if (InstrumentationHelper.ENABLED) { InstrumentationHelper.get().qEvent(eventBean, services.getRuntimeURI(), false); } services.getEventProcessingRWLock().acquireReadLock(); try { processMatches(eventBean); } catch (RuntimeException ex) { matchesArrayThreadLocal.get().clear(); throw ex; } finally { insertIntoLatch.done(); services.getEventProcessingRWLock().releaseReadLock(); if (InstrumentationHelper.ENABLED) { InstrumentationHelper.get().aEvent(); } } dispatch(); }
public void initialize() { initThreadLocals(); threadWorkQueue = new ThreadWorkQueue(); }
handleFilterFault(handle, theEvent, filterFaultCount);