com.espertech.esper.core.service
Interface EPRuntimeSPI

All Superinterfaces:
EPRuntime
All Known Implementing Classes:
EPRuntimeImpl

public interface EPRuntimeSPI
extends EPRuntime

SPI interface of the runtime exposes fire-and-forget, non-continuous query functionality.


Method Summary
 void clearCaches()
          Clear short-lived memory that may temporarily retain references to stopped or destroyed statements.
 void destroy()
           
 void dispatch()
           
 java.lang.String getEngineURI()
           
 long getRoutedExternal()
          Number of events routed externally.
 long getRoutedInternal()
          Number of events routed internally.
 java.util.Map<java.lang.String,java.lang.Long> getStatementNearestSchedules()
           
 java.lang.Class getVariableType(java.lang.String variableName)
          Returns a variable's type.
 java.util.Map<java.lang.String,java.lang.Class> getVariableTypeAll()
          Returns all declared variable names and their types.
 void initialize()
           
 void processThreadWorkQueue()
           
 void processWrappedEvent(EventBean eventBean)
           
 EventBean wrapEvent(java.util.Map map, java.lang.String eventTypeName)
          Send a map containing event property values to the event stream processing runtime.
 EventBean wrapEvent(org.w3c.dom.Node node)
          Send an event represented by a DOM node to the event stream processing runtime.
 EventBean wrapEvent(java.lang.Object object)
          Send an event represented by a plain Java object to the event stream processing runtime.
 
Methods inherited from interface com.espertech.esper.client.EPRuntime
executeQuery, executeQuery, executeQuery, executeQuery, executeQuery, executeQuery, getCurrentTime, getDataFlowRuntime, getEventRenderer, getEventSender, getEventSender, getNextScheduledTime, getNumEventsEvaluated, getVariableValue, getVariableValue, getVariableValue, getVariableValueAll, isExternalClockingEnabled, prepareQuery, prepareQuery, prepareQueryWithParameters, resetStats, route, route, route, route, sendEvent, sendEvent, sendEvent, sendEvent, setUnmatchedListener, setVariableValue, setVariableValue, setVariableValue
 

Method Detail

getVariableTypeAll

java.util.Map<java.lang.String,java.lang.Class> getVariableTypeAll()
Returns all declared variable names and their types.

Returns:
variable names and types

getVariableType

java.lang.Class getVariableType(java.lang.String variableName)
Returns a variable's type.

Parameters:
variableName - type or null if the variable is not declared
Returns:
type of variable

getRoutedInternal

long getRoutedInternal()
Number of events routed internally.

Returns:
event count routed internally

getRoutedExternal

long getRoutedExternal()
Number of events routed externally.

Returns:
event count routed externally

destroy

void destroy()

getStatementNearestSchedules

java.util.Map<java.lang.String,java.lang.Long> getStatementNearestSchedules()

wrapEvent

EventBean wrapEvent(java.lang.Object object)
Send an event represented by a plain Java object to the event stream processing runtime.

Use the route method for sending events into the runtime from within UpdateListener code, to avoid the possibility of a stack overflow due to nested calls to sendEvent.

Parameters:
object - is the event to sent to the runtime
Throws:
EPException - is thrown when the processing of the event lead to an error

wrapEvent

EventBean wrapEvent(java.util.Map map,
                    java.lang.String eventTypeName)
Send a map containing event property values to the event stream processing runtime.

Use the route method for sending events into the runtime from within UpdateListener code. to avoid the possibility of a stack overflow due to nested calls to sendEvent.

Parameters:
map - - map that contains event property values. Keys are expected to be of type String while values can be of any type. Keys and values should match those declared via Configuration for the given eventTypeName.
eventTypeName - - the name for the Map event type that was previously configured
Throws:
EPException - - when the processing of the event leads to an error

wrapEvent

EventBean wrapEvent(org.w3c.dom.Node node)
Send an event represented by a DOM node to the event stream processing runtime.

Use the route method for sending events into the runtime from within UpdateListener code. to avoid the possibility of a stack overflow due to nested calls to sendEvent.

Parameters:
node - is the DOM node as an event
Throws:
EPException - is thrown when the processing of the event lead to an error

processThreadWorkQueue

void processThreadWorkQueue()

dispatch

void dispatch()

initialize

void initialize()

processWrappedEvent

void processWrappedEvent(EventBean eventBean)

getEngineURI

java.lang.String getEngineURI()

clearCaches

void clearCaches()
Clear short-lived memory that may temporarily retain references to stopped or destroyed statements.

Use this method after stopping and destroying statements for the purpose of clearing thread-local or other short lived storage to statement handles of deleted statements.

NOT safe to use without first acquiring the engine lock.


© 2006-2015 EsperTech Inc.
All rights reserved.
Visit us at espertech.com