|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectcom.espertech.esper.core.service.ConfigurationOperationsImpl
public class ConfigurationOperationsImpl
Provides runtime engine configuration operations.
Constructor Summary | |
---|---|
ConfigurationOperationsImpl(EventAdapterService eventAdapterService,
EventTypeIdGenerator eventTypeIdGenerator,
EngineImportService engineImportService,
VariableService variableService,
EngineSettingsService engineSettingsService,
ValueAddEventService valueAddEventService,
MetricReportingService metricReportingService,
StatementEventTypeRef statementEventTypeRef,
StatementVariableRef statementVariableRef,
PluggableObjectCollection plugInViews,
FilterService filterService,
PatternSubexpressionPoolEngineSvc patternSubexpressionPoolSvc,
TableService tableService)
Ctor. |
Method Summary | |
---|---|
void |
addEventType(java.lang.Class javaEventClass)
Add a name for an event type represented by Java-bean plain-old Java object events, using the simple name of the Java class as the name. |
void |
addEventType(java.lang.String eventTypeName,
java.lang.Class javaEventClass)
Add an name for an event type represented by Java-bean plain-old Java object events. |
void |
addEventType(java.lang.String eventTypeName,
ConfigurationEventTypeXMLDOM xmlDOMEventTypeDesc)
Add an name for an event type that represents org.w3c.dom.Node events. |
void |
addEventType(java.lang.String eventTypeName,
java.util.Map<java.lang.String,java.lang.Object> typeMap)
Add an name for an event type that represents java.util.Map events, and for which each property may itself be a Map of further properties, with unlimited nesting levels. |
void |
addEventType(java.lang.String eventTypeName,
java.util.Map<java.lang.String,java.lang.Object> typeMap,
ConfigurationEventTypeMap mapConfig)
Add a name for an event type that represents java.util.Map events, and for which each property may itself be a Map of further properties, with unlimited nesting levels. |
void |
addEventType(java.lang.String eventTypeName,
java.util.Map<java.lang.String,java.lang.Object> typeMap,
java.lang.String[] superTypes)
Add a name for an event type that represents java.util.Map events, and for which each property may itself be a Map of further properties, with unlimited nesting levels. |
void |
addEventType(java.lang.String eventTypeName,
java.util.Properties typeMap)
Add an event type that represents java.util.Map events. |
void |
addEventType(java.lang.String eventTypeName,
java.lang.String javaEventClassName)
Add an name for an event type represented by JavaBean object events. |
void |
addEventType(java.lang.String eventTypeName,
java.lang.String[] propertyNames,
java.lang.Object[] propertyTypes)
Add an event type that represents Object-array (Object[]) events. |
void |
addEventType(java.lang.String eventTypeName,
java.lang.String[] propertyNames,
java.lang.Object[] propertyTypes,
ConfigurationEventTypeObjectArray optionalConfiguration)
Add an event type that represents Object-array (Object[]) events. |
void |
addEventType(java.lang.String eventTypeName,
java.lang.String eventClass,
ConfigurationEventTypeLegacy legacyEventTypeDesc)
Add an name for an event type that represents legacy Java type (non-JavaBean style) events. |
void |
addEventTypeAutoName(java.lang.String javaPackageName)
Adds a Java package name of a package that Java event classes reside in. |
void |
addImport(java.lang.Class importClass)
Adds a class to the list of automatically-imported classes. |
void |
addImport(java.lang.String importName)
Adds a package or class to the list of automatically-imported classes and packages. |
void |
addPlugInAggregationFunctionFactory(java.lang.String functionName,
java.lang.String aggregationFactoryClassName)
Adds a plug-in aggregation function given a EPL function name and an aggregation factory class name. |
void |
addPlugInAggregationMultiFunction(ConfigurationPlugInAggregationMultiFunction config)
Adds a plug-in aggregation multi-function. |
void |
addPlugInEventType(java.lang.String eventTypeName,
java.net.URI[] resolutionURIs,
java.io.Serializable initializer)
Adds an name for an event type that one of the plug-in event representations resolves to an event type. |
void |
addPlugInSingleRowFunction(java.lang.String functionName,
java.lang.String className,
java.lang.String methodName)
Adds a plug-in single-row function given a EPL function name, a class name and a method name. |
void |
addPlugInSingleRowFunction(java.lang.String functionName,
java.lang.String className,
java.lang.String methodName,
ConfigurationPlugInSingleRowFunction.FilterOptimizable filterOptimizable)
Adds a plug-in single-row function given a EPL function name, a class name, method name and setting for value-cache behavior. |
void |
addPlugInSingleRowFunction(java.lang.String functionName,
java.lang.String className,
java.lang.String methodName,
ConfigurationPlugInSingleRowFunction.ValueCache valueCache)
Adds a plug-in single-row function given a EPL function name, a class name, method name and setting for value-cache behavior. |
void |
addPlugInSingleRowFunction(java.lang.String functionName,
java.lang.String className,
java.lang.String methodName,
ConfigurationPlugInSingleRowFunction.ValueCache valueCache,
ConfigurationPlugInSingleRowFunction.FilterOptimizable filterOptimizable,
boolean rethrowExceptions)
Adds a plug-in single-row function given a EPL function name, a class name, method name and setting for value-cache behavior. |
void |
addPlugInView(java.lang.String namespace,
java.lang.String name,
java.lang.String viewFactoryClass)
Add a new plug-in view for use as a data window or derived value view. |
void |
addRevisionEventType(java.lang.String revisioneventTypeName,
ConfigurationRevisionEventType revisionEventTypeConfig)
Adds an revision event type. |
void |
addVariable(java.lang.String variableName,
java.lang.Class type,
java.lang.Object initializationValue)
Add a global variable. |
void |
addVariable(java.lang.String variableName,
java.lang.String eventTypeName,
java.lang.Object initializationValue)
Add a global variable. |
void |
addVariable(java.lang.String variableName,
java.lang.String type,
java.lang.Object initializationValue,
boolean constant)
Add a global variable, allowing constants. |
void |
addVariantStream(java.lang.String varianteventTypeName,
ConfigurationVariantStream variantStreamConfig)
Adds a new variant stream. |
EventType |
getEventType(java.lang.String eventTypeName)
Returns the event type for a given event type name. |
java.util.Set<java.lang.String> |
getEventTypeNameUsedBy(java.lang.String name)
Return the set of statement names of statements that are in started or stopped state and that reference the given event type name. |
EventType[] |
getEventTypes()
Returns an array of event types tracked or available within the engine in any order. |
java.util.Set<java.lang.String> |
getVariableNameUsedBy(java.lang.String variableName)
Return the set of statement names of statements that are in started or stopped state and that reference the given variable name. |
boolean |
isEventTypeExists(java.lang.String eventTypeName)
Checks if an eventTypeName has already been registered for that name. |
boolean |
isVariantStreamExists(java.lang.String name)
Returns true if a variant stream by the name has been declared, or false if not. |
boolean |
removeEventType(java.lang.String name,
boolean force)
Remove an event type by its name, returning an indicator whether the event type was found and removed. |
boolean |
removeVariable(java.lang.String name,
boolean force)
Remove a global non-context-partitioned variable by its name, returning an indicator whether the variable was found and removed. |
void |
replaceXMLEventType(java.lang.String xmlEventTypeName,
ConfigurationEventTypeXMLDOM config)
Rebuild the XML event type based on changed type informaton, please read below for limitations. |
void |
setMetricsReportingDisabled()
Disable engine-level metrics reporting. |
void |
setMetricsReportingEnabled()
Enable engine-level metrics reporting. |
void |
setMetricsReportingInterval(java.lang.String stmtGroupName,
long newInterval)
Sets a new interval for metrics reporting for a pre-configured statement group, or changes the default statement reporting interval if supplying a null value for the statement group name. |
void |
setMetricsReportingStmtDisabled(java.lang.String statementName)
Disable metrics reporting for a given statement. |
void |
setMetricsReportingStmtEnabled(java.lang.String statementName)
Enable metrics reporting for the given statement. |
void |
setPatternMaxSubexpressions(java.lang.Long maxSubexpressions)
Set the current maximum pattern sub-expression count. |
void |
setPlugInEventTypeResolutionURIs(java.net.URI[] urisToResolveName)
Sets the URIs that point to plug-in event representations that are given a chance to dynamically resolve an event type name to an event type, when a new (unseen) event type name occurs in a new EPL statement. |
void |
updateMapEventType(java.lang.String mapeventTypeName,
java.util.Map<java.lang.String,java.lang.Object> typeMap)
Updates an existing Map event type with additional properties. |
void |
updateObjectArrayEventType(java.lang.String objectArrayEventTypeName,
java.lang.String[] propertyNames,
java.lang.Object[] propertyTypes)
Updates an existing Object-array event type with additional properties. |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
public ConfigurationOperationsImpl(EventAdapterService eventAdapterService, EventTypeIdGenerator eventTypeIdGenerator, EngineImportService engineImportService, VariableService variableService, EngineSettingsService engineSettingsService, ValueAddEventService valueAddEventService, MetricReportingService metricReportingService, StatementEventTypeRef statementEventTypeRef, StatementVariableRef statementVariableRef, PluggableObjectCollection plugInViews, FilterService filterService, PatternSubexpressionPoolEngineSvc patternSubexpressionPoolSvc, TableService tableService)
eventAdapterService
- is the event wrapper and type serviceengineImportService
- for imported aggregation functions and static functionsvariableService
- - provides access to variable valuesengineSettingsService
- - some engine settings are writablevalueAddEventService
- - update event handlingmetricReportingService
- - for metric reportingstatementEventTypeRef
- - statement to event type reference holdingstatementVariableRef
- - statement to variable reference holdingMethod Detail |
---|
public void addEventTypeAutoName(java.lang.String javaPackageName)
ConfigurationOperations
This setting allows an application to place all it's events into one or more Java packages and then declare these packages via this method. The engine attempts to resolve an event type name to a Java class residing in each declared package.
For example, in the statement "select * from MyEvent" the engine attempts to load class "javaPackageName.MyEvent" and if successful, uses that class as the event type.
addEventTypeAutoName
in interface ConfigurationOperations
javaPackageName
- is the fully-qualified Java package name of the Java package that event classes reside inpublic void addPlugInView(java.lang.String namespace, java.lang.String name, java.lang.String viewFactoryClass)
ConfigurationOperations
addPlugInView
in interface ConfigurationOperations
namespace
- view namespace namename
- view nameviewFactoryClass
- factory class of viewpublic void addPlugInAggregationMultiFunction(ConfigurationPlugInAggregationMultiFunction config) throws ConfigurationException
ConfigurationOperations
addPlugInAggregationMultiFunction
in interface ConfigurationOperations
config
- the configuration
ConfigurationException
- is thrown to indicate a configuration problempublic void addPlugInAggregationFunctionFactory(java.lang.String functionName, java.lang.String aggregationFactoryClassName)
ConfigurationOperations
The same function name cannot be added twice.
addPlugInAggregationFunctionFactory
in interface ConfigurationOperations
functionName
- is the new aggregation function name for use in EPLaggregationFactoryClassName
- is the fully-qualified class name of the class implementing the aggregation function factory interface AggregationFunctionFactory
public void addPlugInSingleRowFunction(java.lang.String functionName, java.lang.String className, java.lang.String methodName) throws ConfigurationException
ConfigurationOperations
The same function name cannot be added twice.
addPlugInSingleRowFunction
in interface ConfigurationOperations
functionName
- is the new single-row function name for use in EPLclassName
- is the fully-qualified class name of the class implementing the single-row functionmethodName
- is the public static method provided by the class that implements the single-row function
ConfigurationException
- is thrown to indicate a problem adding the single-row functionpublic void addPlugInSingleRowFunction(java.lang.String functionName, java.lang.String className, java.lang.String methodName, ConfigurationPlugInSingleRowFunction.ValueCache valueCache) throws ConfigurationException
ConfigurationOperations
The same function name cannot be added twice.
addPlugInSingleRowFunction
in interface ConfigurationOperations
functionName
- is the new single-row function name for use in EPLclassName
- is the fully-qualified class name of the class implementing the single-row functionmethodName
- is the public static method provided by the class that implements the single-row functionvalueCache
- set the behavior for caching the return value when constant parameters are provided
ConfigurationException
- is thrown to indicate a problem adding the single-row functionpublic void addPlugInSingleRowFunction(java.lang.String functionName, java.lang.String className, java.lang.String methodName, ConfigurationPlugInSingleRowFunction.FilterOptimizable filterOptimizable) throws ConfigurationException
ConfigurationOperations
The same function name cannot be added twice.
addPlugInSingleRowFunction
in interface ConfigurationOperations
functionName
- is the new single-row function name for use in EPLclassName
- is the fully-qualified class name of the class implementing the single-row functionmethodName
- is the public static method provided by the class that implements the single-row functionfilterOptimizable
- whether the single-row function, when used in filters, may be subject to reverse index lookup based on the function result
ConfigurationException
- is thrown to indicate a problem adding the single-row functionpublic void addPlugInSingleRowFunction(java.lang.String functionName, java.lang.String className, java.lang.String methodName, ConfigurationPlugInSingleRowFunction.ValueCache valueCache, ConfigurationPlugInSingleRowFunction.FilterOptimizable filterOptimizable, boolean rethrowExceptions) throws ConfigurationException
ConfigurationOperations
The same function name cannot be added twice.
addPlugInSingleRowFunction
in interface ConfigurationOperations
functionName
- is the new single-row function name for use in EPLclassName
- is the fully-qualified class name of the class implementing the single-row functionmethodName
- is the public static method provided by the class that implements the single-row functionvalueCache
- set the behavior for caching the return value when constant parameters are providedfilterOptimizable
- whether the single-row function, when used in filters, may be subject to reverse index lookup based on the function resultrethrowExceptions
- whether exceptions generated by the UDF are rethrown
ConfigurationException
- is thrown to indicate a problem adding the single-row functionpublic void addImport(java.lang.String importName)
ConfigurationOperations
To import a single class offering a static method, simply supply the fully-qualified name of the class
and use the syntax classname.methodname(...)
To import a whole package and use the classname.methodname(...)
syntax, specifiy a package
with wildcard, such as com.mycompany.staticlib.*
.
addImport
in interface ConfigurationOperations
importName
- is a fully-qualified class name or a package name with wildcardpublic void addImport(java.lang.Class importClass)
ConfigurationOperations
Use #addImport(String) to import a package.
addImport
in interface ConfigurationOperations
importClass
- is a class to importpublic boolean isEventTypeExists(java.lang.String eventTypeName)
ConfigurationOperations
isEventTypeExists
in interface ConfigurationOperations
eventTypeName
- the name
public void addEventType(java.lang.String eventTypeName, java.lang.String javaEventClassName)
ConfigurationOperations
Allows a second name to be added for the same type. Does not allow the same name to be used for different types.
Note that when adding multiple names for the same Java class the names represent an alias to the same event type since event type identity for Java classes is per Java class.
addEventType
in interface ConfigurationOperations
eventTypeName
- is the name for the event typejavaEventClassName
- fully-qualified class name of the event typepublic void addEventType(java.lang.String eventTypeName, java.lang.Class javaEventClass)
ConfigurationOperations
Allows a second name to be added for the same type. Does not allow the same name to be used for different types.
Note that when adding multiple names for the same Java class the names represent an alias to the same event type since event type identity for Java classes is per Java class.
addEventType
in interface ConfigurationOperations
eventTypeName
- is the name for the event typejavaEventClass
- is the Java event class for which to create the namepublic void addEventType(java.lang.Class javaEventClass)
ConfigurationOperations
For example, if your class is "com.mycompany.MyEvent", then this method adds the name "MyEvent" for the class.
Allows a second name to be added for the same type. Does not allow the same name to be used for different types.
addEventType
in interface ConfigurationOperations
javaEventClass
- is the Java event class for which to create the name from the class simple namepublic void addEventType(java.lang.String eventTypeName, java.util.Properties typeMap)
ConfigurationOperations
Allows a second name to be added for the same type. Does not allow the same name to be used for different types.
addEventType
in interface ConfigurationOperations
eventTypeName
- is the name for the event typetypeMap
- maps the name of each property in the Map event to the type
(fully qualified classname) of its value in Map event instances.public void addEventType(java.lang.String eventTypeName, java.util.Map<java.lang.String,java.lang.Object> typeMap)
ConfigurationOperations
Each entry in the type mapping must contain the String property name as the key value,
and either a Class, or a further Map
addEventType
in interface ConfigurationOperations
eventTypeName
- is the name for the event typetypeMap
- maps the name of each property in the Map event to the type
(fully qualified classname) of its value in Map event instances.
public void addEventType(java.lang.String eventTypeName, java.util.Map<java.lang.String,java.lang.Object> typeMap, java.lang.String[] superTypes) throws ConfigurationException
ConfigurationOperations
Each entry in the type mapping must contain the String property name as the key value,
and either a Class, or a further Map
addEventType
in interface ConfigurationOperations
eventTypeName
- is the name for the event typetypeMap
- maps the name of each property in the Map event to the type
(fully qualified classname) of its value in Map event instances.superTypes
- is an array of event type name of further Map types that this
ConfigurationException
- if the name is already in used for a different type
public void addEventType(java.lang.String eventTypeName, java.util.Map<java.lang.String,java.lang.Object> typeMap, ConfigurationEventTypeMap mapConfig) throws ConfigurationException
ConfigurationOperations
Each entry in the type mapping must contain the String property name as the key value,
and either a Class, or a further Map
addEventType
in interface ConfigurationOperations
eventTypeName
- is the name for the event typetypeMap
- maps the name of each property in the Map event to the type
(fully qualified classname) of its value in Map event instances.mapConfig
- is the Map-event type configuration that may defined super-types, timestamp-property-name etc.
ConfigurationException
- if the name is already in used for a different type
public void addEventType(java.lang.String eventTypeName, java.lang.String[] propertyNames, java.lang.Object[] propertyTypes) throws ConfigurationException
ConfigurationOperations
addEventType
in interface ConfigurationOperations
eventTypeName
- is the name for the event typepropertyNames
- name of each property, length must match number of typespropertyTypes
- type of each property, length must match number of names
ConfigurationException
- if the name is already in used for a different typepublic void addEventType(java.lang.String eventTypeName, java.lang.String[] propertyNames, java.lang.Object[] propertyTypes, ConfigurationEventTypeObjectArray optionalConfiguration) throws ConfigurationException
ConfigurationOperations
addEventType
in interface ConfigurationOperations
eventTypeName
- is the name for the event typepropertyNames
- name of each property, length must match number of typespropertyTypes
- type of each property, length must match number of namesoptionalConfiguration
- object-array type configuration
ConfigurationException
- if the name is already in used for a different typepublic void addEventType(java.lang.String eventTypeName, ConfigurationEventTypeXMLDOM xmlDOMEventTypeDesc)
ConfigurationOperations
Allows a second name to be added for the same type. Does not allow the same name to be used for different types.
addEventType
in interface ConfigurationOperations
eventTypeName
- is the name for the event typexmlDOMEventTypeDesc
- descriptor containing property and mapping information for XML-DOM eventspublic void addVariable(java.lang.String variableName, java.lang.Class type, java.lang.Object initializationValue) throws ConfigurationException
ConfigurationOperations
Use the runtime API to set variable values or EPL statements to change variable values.
addVariable
in interface ConfigurationOperations
variableName
- name of the variable to addtype
- the type name of the variable, must be a primitive or boxed Java-builtin scalar type or "object" for any
value or an event type name or a class name or fully-qualified class name. Append "[]" for array.initializationValue
- is the first assigned value.
For static initialization via the Configuration
object the value can be string-typed and will be parsed.
For static initialization the initialization value, if provided, must implement Serializable
or Externalizable
.
ConfigurationException
- if the type and initialization value don't match or the variable name
is already in usepublic void addVariable(java.lang.String variableName, java.lang.String eventTypeName, java.lang.Object initializationValue) throws ConfigurationException
ConfigurationOperations
Use the runtime API to set variable values or EPL statements to change variable values.
addVariable
in interface ConfigurationOperations
variableName
- name of the variable to addeventTypeName
- the type name of the variable, must be a primitive or boxed Java-builtin scalar type or "object" for any
value or an event type name or a class name or fully-qualified class name. Append "[]" for array.initializationValue
- is the first assigned value
For static initialization via the Configuration
object the value can be string-typed and will be parsed.
For static initialization the initialization value, if provided, must implement Serializable
or Externalizable
.
ConfigurationException
- if the type and initialization value don't match or the variable name
is already in usepublic void addVariable(java.lang.String variableName, java.lang.String type, java.lang.Object initializationValue, boolean constant) throws ConfigurationException
ConfigurationOperations
Use the runtime API to set variable values or EPL statements to change variable values.
addVariable
in interface ConfigurationOperations
variableName
- name of the variable to addtype
- the type name of the variable, must be a primitive or boxed Java-builtin scalar type or "object" for any
value or an event type name or a class name or fully-qualified class name. Append "[]" for array.initializationValue
- is the first assigned value
For static initialization via the Configuration
object the value can be string-typed and will be parsed.
For static initialization the initialization value, if provided, must implement Serializable
or Externalizable
.constant
- true to identify the variable as a constant
ConfigurationException
- if the type and initialization value don't match or the variable name
is already in usepublic void addPlugInEventType(java.lang.String eventTypeName, java.net.URI[] resolutionURIs, java.io.Serializable initializer)
ConfigurationOperations
The order of the URIs matters as event representations are asked in turn, to accept the event type.
URIs can be child URIs of plug-in event representations and can add additional parameters or fragments for use by the event representation.
addPlugInEventType
in interface ConfigurationOperations
eventTypeName
- is the name of the event typeresolutionURIs
- is URIs that are matched to registered event representationsinitializer
- is an optional value for parameterizing or configuring the event typepublic void setPlugInEventTypeResolutionURIs(java.net.URI[] urisToResolveName)
ConfigurationOperations
The order of the URIs matters as event representations are asked in turn, to accept the name.
URIs can be child URIs of plug-in event representations and can add additional parameters or fragments for use by the event representation.
setPlugInEventTypeResolutionURIs
in interface ConfigurationOperations
urisToResolveName
- URIs for resolving the namepublic void addRevisionEventType(java.lang.String revisioneventTypeName, ConfigurationRevisionEventType revisionEventTypeConfig)
ConfigurationOperations
addRevisionEventType
in interface ConfigurationOperations
revisioneventTypeName
- the name of the revision event typerevisionEventTypeConfig
- the configurationpublic void addVariantStream(java.lang.String varianteventTypeName, ConfigurationVariantStream variantStreamConfig)
ConfigurationOperations
addVariantStream
in interface ConfigurationOperations
varianteventTypeName
- is the name of the variant streamvariantStreamConfig
- the configuration such as variant type names and any-type settingpublic void updateMapEventType(java.lang.String mapeventTypeName, java.util.Map<java.lang.String,java.lang.Object> typeMap) throws ConfigurationException
ConfigurationOperations
Does not update existing properties of the updated Map event type.
Adds additional nested properties to nesting levels, if any.
Each entry in the type mapping must contain the String property name of the additional property
and either a Class or further Map
Map event types can only be updated at runtime, at configuration time updates are not allowed.
The type Map may list previously declared properties or can also contain only the new properties to be added.
updateMapEventType
in interface ConfigurationOperations
mapeventTypeName
- the name of the map event type to updatetypeMap
- a Map of string property name and type
ConfigurationException
- if the event type name could not be found or is not a Map
public void updateObjectArrayEventType(java.lang.String objectArrayEventTypeName, java.lang.String[] propertyNames, java.lang.Object[] propertyTypes) throws ConfigurationException
ConfigurationOperations
Does not update existing properties of the updated Object-array event type.
Adds additional nested properties to nesting levels, if any.
Object-array event types can only be updated at runtime, at configuration time updates are not allowed.
The type properties may list previously declared properties or can also contain only the new properties to be added.
updateObjectArrayEventType
in interface ConfigurationOperations
objectArrayEventTypeName
- the name of the object-array event type to updatepropertyNames
- property namespropertyTypes
- property types
ConfigurationException
- if the event type name could not be found or is not a Mappublic void replaceXMLEventType(java.lang.String xmlEventTypeName, ConfigurationEventTypeXMLDOM config) throws ConfigurationException
ConfigurationOperations
Your application must ensure that the rebuild type information is compatible with existing EPL statements and existing events.
The method can be used to change XPath expressions of existing attributes and to reload the schema and to add attributes.
It is not recommended to remove attributes, change attribute type or change the root element name or namespace, or to change type configuration other then as above.
If an existing EPL statement exists that refers to the event type then changes to the event type do not become visible for those existing statements.
replaceXMLEventType
in interface ConfigurationOperations
xmlEventTypeName
- the name of the XML event typeconfig
- the new type configuration
ConfigurationException
- thrown when the type information change failedpublic void setMetricsReportingInterval(java.lang.String stmtGroupName, long newInterval)
ConfigurationOperations
setMetricsReportingInterval
in interface ConfigurationOperations
stmtGroupName
- name of statement group, provide a null value for the default statement interval (default group)newInterval
- millisecond interval, use zero or negative value to disablepublic void setMetricsReportingStmtEnabled(java.lang.String statementName)
ConfigurationOperations
This operation can only be performed at runtime and is not available at engine initialization time.
Statement metric reporting follows the configured default or statement group interval.
Only if metrics reporting (on the engine level) has been enabled at initialization time can statement-level metrics reporting be enabled through this method.
setMetricsReportingStmtEnabled
in interface ConfigurationOperations
statementName
- for which to enable metrics reportingpublic void setMetricsReportingStmtDisabled(java.lang.String statementName)
ConfigurationOperations
setMetricsReportingStmtDisabled
in interface ConfigurationOperations
statementName
- for which to disable metrics reportingpublic void setMetricsReportingEnabled()
ConfigurationOperations
Use this operation to control, at runtime, metrics reporting globally.
Only if metrics reporting (on the engine level) has been enabled at initialization time can metrics reporting be re-enabled at runtime through this method.
setMetricsReportingEnabled
in interface ConfigurationOperations
public void setMetricsReportingDisabled()
ConfigurationOperations
Use this operation to control, at runtime, metrics reporting globally. Setting metrics reporting to disabled removes all performance cost for metrics reporting.
setMetricsReportingDisabled
in interface ConfigurationOperations
public boolean isVariantStreamExists(java.lang.String name)
ConfigurationOperations
isVariantStreamExists
in interface ConfigurationOperations
name
- of variant stream
public boolean removeEventType(java.lang.String name, boolean force) throws ConfigurationException
ConfigurationOperations
This method deletes the event type by it's name from the memory of the engine, thereby allowing that the name to be reused for a new event type and disallowing new statements that attempt to use the deleted name.
If there are one or more statements in started or stopped state that reference the event type, this operation throws ConfigurationException unless the force flag is passed.
If using the force flag to remove the type while statements use the type, the exact behavior of the engine depends on the event representation of the deleted event type and is thus not well defined. It is recommended to destroy statements that use the type before removing the type. Use #geteventTypeNameUsedBy to obtain a list of statements that use a type.
The method can be used for event types implicitly created for insert-into streams and for named windows. The method does not remove variant streams and does not remove revision event types.
removeEventType
in interface ConfigurationOperations
name
- the name of the event type to removeforce
- false to include a check that the type is no longer in use, true to force the remove
even though there can be one or more statements relying on that type
ConfigurationException
- thrown to indicate that the remove operation failedpublic boolean removeVariable(java.lang.String name, boolean force) throws ConfigurationException
ConfigurationOperations
This method deletes the variable by it's name from the memory of the engine, thereby allowing that the name to be reused for a new variable and disallowing new statements that attempt to use the deleted name.
If there are one or more statements in started or stopped state that reference the variable, this operation throws ConfigurationException unless the force flag is passed.
If using the force flag to remove the variable while statements use the variable, the exact behavior is not well defined and affected statements may log errors. It is recommended to destroy statements that use the variable before removing the variable. Use #getVariableNameUsedBy to obtain a list of statements that use a variable.
removeVariable
in interface ConfigurationOperations
name
- the name of the variable to removeforce
- false to include a check that the variable is no longer in use, true to force the remove
even though there can be one or more statements relying on that variable
ConfigurationException
- thrown to indicate that the remove operation failedpublic java.util.Set<java.lang.String> getEventTypeNameUsedBy(java.lang.String name)
ConfigurationOperations
A reference counts as any mention of the event type in a from-clause, a pattern, a insert-into or as part of on-trigger.
getEventTypeNameUsedBy
in interface ConfigurationOperations
name
- name of the event type
public java.util.Set<java.lang.String> getVariableNameUsedBy(java.lang.String variableName)
ConfigurationOperations
A reference counts as any mention of the variable in any expression.
getVariableNameUsedBy
in interface ConfigurationOperations
variableName
- name of the variable
public EventType getEventType(java.lang.String eventTypeName)
ConfigurationOperations
This operation is not available for static configuration and is only available for runtime use.
getEventType
in interface ConfigurationOperations
eventTypeName
- to return event type for
public EventType[] getEventTypes()
ConfigurationOperations
Event types that are associated to statement output may not necessarily be returned as such types, depending on the statement, are considered anonymous.
This operation is not available for static configuration and is only available for runtime use.
getEventTypes
in interface ConfigurationOperations
public void addEventType(java.lang.String eventTypeName, java.lang.String eventClass, ConfigurationEventTypeLegacy legacyEventTypeDesc)
ConfigurationOperations
This operation cannot be used to change an existing type.
Note that when adding multiple names for the same Java class the names represent an alias to the same event type since event type identity for Java classes is per Java class.
addEventType
in interface ConfigurationOperations
eventTypeName
- is the name for the event typeeventClass
- fully-qualified class name of the event typelegacyEventTypeDesc
- descriptor containing property and mapping information for Legacy Java type eventspublic void setPatternMaxSubexpressions(java.lang.Long maxSubexpressions)
ConfigurationOperations
Use null to indicate that there is not current maximum.
setPatternMaxSubexpressions
in interface ConfigurationOperations
maxSubexpressions
- to set
|
© 2006-2015 EsperTech Inc. All rights reserved. Visit us at espertech.com |
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |