Top
Interstage Big DataComplex Event Processing Server V1.1.0 Developer's Reference
FUJITSU Software

1.1.8 Annotation

Annotations attach additional information to individual complex event processing statements. Describe an annotation before the complex event processing statement to which you want to add information.

Annotation type

Notation

Explanation

Name

@Name("name")

or @Name('name')

Attaches name to a complex event processing statement. Attaching a unique name makes it easier to distinguish output information during debugging.

When you attach the same name to multiple complex event processing statements, two hyphens "--" and a number will be automatically appended to make unique names.

If the @Name annotation is not specified, a unique name among the rules, such as "0b0562a2-56e7-4cf3-a520-cb1e16ef2992", is automatically assigned.

SoapListener

@SoapListener("listenerDefinition") or

@SoapListener('listenerDefinition')

Associates a listener definition with a SELECT statement. For listenerDefinition, specify the "development asset ID" specified at "listener definition". This passes the SELECT statement output as a SOAP message to the user-developed Web service specified in the listener definition.

DebugLogListener

@DebugLogListener

Outputs logs for debugging complex event processing statements.

LoggingListener

@LoggingListener(table="logStorageArea", properties="propertyNamesToBeOutput")

or the same format but with single quotation marks (') instead of double quotation marks (")

Logs the complex event processing statement output results to logStorageArea.

Specify the output destination of the Hadoop system in logStorageArea using a full path. Even if events are to be recorded in the engine log, specify with a virtual path name beginning with a slash, such as "/eventName", to distinguish events.

In propertyNamesToBeOutput, specify the property names to be output by the complex event processing statement, separated by commas.

CustomListener

@CustomListener(mainClass="userDevelopedJavaClassName"[, args={"argument1", "argument2", ...}])

or the same format but with single quotation marks (') instead of double quotation marks (")

Passes the output of the complex event processing statement to a user-developed Java class.

In userDevelopedJavaClassName, specify the name of the Java class that accepts the result of the complex event processing statement. Specify this name in FQCN format (which includes the package name). The CustomListener interface must have been implemented for this Java class.

Specify argument1 and argument2 to pass certain arguments to a user-developed Java class. If there is no need to pass arguments, you can omit args.

Information

Annotation execution sequence

If the @SoapListener, @DebugLogListener, @LoggingListener, and @CustomListener annotations are specified simultaneously for one complex event processing statement, the output processing of each annotation is executed in the sequence in which they are specified.

@SoapListener('LISTEN01')
@DebugLogListener

select gatewayId, value from EVENT_01;

In the above example, the sequence of output execution is @SoapListener, then @DebugLogListener.