The latest version for DAS is WSO2 Data Analytics Server 3.1.0. View documentation for the latest release.
WSO2 Data Analytics Server is succeeded by WSO2 Stream Processor. To view the latest documentation for WSO2 SP, see WSO2 Stream Processor Documentation.

All docs This doc

Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

...

 The annotations supported for execution plans are as follows. 

AnnotationDescriptionExample

@plan:name (<name for execution plan>)

The name of the execution plan.@Plan:name('ExecutionPlan')
@plan:description (<description about execution plan>)

This provides a description about the execution plan. Details such as the business requirement of the execution plan can be mentioned here. 

@Plan:description('This is the description for my NewExecutionPlan')

@plan:async (bufferSize=<event queue size>)WSO2 DAS has a disruptor based implementation to handle streams that are disabled by default.
This annotation can be used to enable the disruptor at execution plan level that affects all the streams in the execution plan. The buffer size is an optional parameter. The default buffer size is 1024.
@plan:async(bufferSize=2)
@async(bufferSize=<event queue size>)Using this you can enable the disruptor only for a specific event stream. The event flow of the specified stream passes through the disruptor when enabled. 

@async(bufferSize='2')
define stream sensor_stream (meta_sensorId int, humidity float, sensorValue double);

@import (<DAS stream definition>)

This is used to import a DAS event stream definition and map it to a Siddhi stream definition. For more information about event stream definitions, see Understanding Event Streams and Event Tables.

@Import('org.wso2.event.sensor.stream:1.0.0')
define stream sensor_stream (meta_sensorId int, humidity float, sensorValue double);

@export (<DAS stream definition>)This is used to export a Siddhi event stream definition and map it to a DAS event stream definition.

@Export('org.wso2.sensor.value.projected.stream:1.0.0')
define stream sensor_value_projected_stream (meta_sensorId int, humidity float, value double);

Step 1: Add execution plan info

...

Query expressions are event processing logic written in Siddhi Query Language. When defining more than one query, each query should end with a semi colon.

Step 4. Export streams 
Anchor
Export Stream
Export Stream

 Defines the mappings between the exported (output) stream of the Siddhi runtime to one of the available event streams (defined inside query expressions). The parameters are as follows.

...