public interface EPRuntime
Modifier and Type | Method and Description |
---|---|
void |
addRuntimeStateListener(EPRuntimeStateListener listener)
Add a listener to runtime state changes that receives a before-destroy event.
|
void |
destroy()
Destroys the runtime.
|
com.espertech.esper.common.client.configuration.Configuration |
getConfigurationDeepCopy()
Returns a deep-copy of the configuration that is actively in use by the runtime.
|
Map<String,Object> |
getConfigurationTransient()
Returns the transient configuration, which are configuration values that are passed by reference (and not by value)
|
Context |
getContext()
Provides naming context for public named objects.
|
com.espertech.esper.common.client.context.EPContextPartitionService |
getContextPartitionService()
Returns the context partition service, for context partition information
|
com.espertech.esper.common.client.dataflow.core.EPDataFlowService |
getDataFlowService()
Returns the data flow service, for managing dataflows
|
EPDeploymentService |
getDeploymentService()
Returns the deployment service, for deploying and undeploying compiled modules
|
EPEventService |
getEventService()
Returns the event service, for sending events to the runtime and for controlling time
|
EPEventTypeService |
getEventTypeService()
Returns the event type service, for obtaining information on event types
|
EPFireAndForgetService |
getFireAndForgetService()
Returns the fire-and-forget service, for executing fire-and-forget queries
|
com.espertech.esper.common.client.metric.EPMetricsService |
getMetricsService()
Returns the metrics service, for managing runtime and statement metrics reporting
|
com.espertech.esper.common.client.render.EPRenderEventService |
getRenderEventService()
Returns the event rendering service, for rendering events to JSON and XML
|
ReadWriteLock |
getRuntimeInstanceWideLock()
Returns the runtime-instance global read-write lock.
|
com.espertech.esper.common.client.EPCompilerPathable |
getRuntimePath()
Returns a path object for use by the compiler that represents the EPL objects deployed into the runtime.
|
String |
getURI()
Returns the runtime URI, or "default" if this is the default runtime.
|
com.espertech.esper.common.client.variable.EPVariableService |
getVariableService()
Returns the variable service, for reading and writing variables
|
void |
initialize()
Frees any resources associated with this runtime instance, and leaves the runtime instance
ready for further use.
|
boolean |
isDestroyed()
Returns true if the runtime is in destroyed state, or false if not.
|
void |
removeAllRuntimeStateListeners()
Remove all listeners to runtime state changes.
|
boolean |
removeRuntimeStateListener(EPRuntimeStateListener listener)
Removate a listener to runtime state changes.
|
EPEventService getEventService() throws EPRuntimeDestroyedException
EPRuntimeDestroyedException
- thrown when the runtime has been destroyedcom.espertech.esper.common.client.dataflow.core.EPDataFlowService getDataFlowService() throws EPRuntimeDestroyedException
EPRuntimeDestroyedException
- thrown when the runtime has been destroyedcom.espertech.esper.common.client.context.EPContextPartitionService getContextPartitionService() throws EPRuntimeDestroyedException
EPRuntimeDestroyedException
- thrown when the runtime has been destroyedcom.espertech.esper.common.client.variable.EPVariableService getVariableService() throws EPRuntimeDestroyedException
EPRuntimeDestroyedException
- thrown when the runtime has been destroyedcom.espertech.esper.common.client.metric.EPMetricsService getMetricsService() throws EPRuntimeDestroyedException
EPRuntimeDestroyedException
- thrown when the runtime has been destroyedEPEventTypeService getEventTypeService() throws EPRuntimeDestroyedException
EPRuntimeDestroyedException
- thrown when the runtime has been destroyedcom.espertech.esper.common.client.render.EPRenderEventService getRenderEventService() throws EPRuntimeDestroyedException
EPRuntimeDestroyedException
- thrown when the runtime has been destroyedEPFireAndForgetService getFireAndForgetService() throws EPRuntimeDestroyedException
EPRuntimeDestroyedException
- thrown when the runtime has been destroyedEPDeploymentService getDeploymentService() throws EPRuntimeDestroyedException
EPRuntimeDestroyedException
- thrown when the runtime has been destroyedboolean isDestroyed()
void initialize()
Do not use the EPDeploymentService
administrative and EPEventService
runtime instances obtained before the
initialize (including related services such as configuration, module management, etc.).
Your application must obtain new administrative and runtime instances.
Retains the existing configuration of the runtime instance but forgets any runtime configuration changes.
Stops and destroys any existing statement resources such as filters, patterns, expressions, views.
String getURI()
Context getContext() throws EPRuntimeDestroyedException
An extension point designed for use by input and output adapters as well as other extension services.
EPRuntimeDestroyedException
- thrown when the runtime instance has been destroyedvoid destroy()
Releases any resources held by the runtime. The runtime enteres a state in which operations provided by the runtime are not guaranteed to operate properly.
Removes the runtime URI from the known URIs. Allows configuration to change for the instance.
When destroying a runtime your application must make sure that threads that are sending events into the runtime have completed their work. More generally, the runtime should not be currently in use during or after the destroy operation.
ReadWriteLock getRuntimeInstanceWideLock() throws EPRuntimeDestroyedException
EPDeploymentService.deploy(EPCompiled)
and EPDeploymentService.undeploy(String)
methods take a write lock.EPRuntimeDestroyedException
- thrown when the runtime has been destroyedvoid addRuntimeStateListener(EPRuntimeStateListener listener)
listener
- to addboolean removeRuntimeStateListener(EPRuntimeStateListener listener)
listener
- to removevoid removeAllRuntimeStateListeners()
com.espertech.esper.common.client.configuration.Configuration getConfigurationDeepCopy()
Note: This can be an expensive operation.
Map<String,Object> getConfigurationTransient()
com.espertech.esper.common.client.EPCompilerPathable getRuntimePath()
Copyright © 2005–2018. All rights reserved.