Versions Compared

Key

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

This page describes how to create artifacts for the Analytics Project. It contains the following sections:

...

The new project has now been created in the workspace. If you browse inside the project, you will see a project structure as below, with folders created for different resources such as execution-plan, publisher, receiver, and stream. 

Creating

...

a Stream

Events are the lifeline of WSO2 CEP/DAS. They not only process data as events, but also interact with external systems using events. Event is a unit of data, and an event stream is a sequence of events of a particular type. The type of events can be defined as an event stream definition.Definitions of the event streams are stored in the file system as deployable artifacts in the  <CARBON _HOME>/repository/deployment/server/executionplanseventstreams/ directory as .siddhiqljson files. More

Creating a new

...

Stream

Follow these steps to create a new execution-planstream. Alternatively, you can import an existing execution-planstream.

  1. Open the Developer Studio Dashboard (click click Developer Studio > Open Dashboard) and click Execution-plan in click Stream in the Analytics category.
  2. Select Select Create New Execution-plan and click Stream and click Next.
  3. Type a unique name for the Execution-planStream.
  4. Do one of the following:
    • To save the
    execution-plan
    • stream in an existing Analytics project in your workspace,
    click
    • click  Browse
    and
    •   and select that project.
    • To save the
    execution-plan
    • stream in a new Analytics project,
    click
    • click Create new Project
    and
    •  and create the new project.
  5. Click Click Finish . The execution-plan stream is created in the execution-plan stream folder under the Analytics project you specified, and the execution-plan stream is open in the editor.

Importing

...

a Stream

Follow these steps to import an existing execution-plan stream from a .siddhiql json file into an Analytics project. Alternatively, you can create a new execution-planstream.

  1. Open the Developer Studio Dashboard (click click Developer Studio > Open Dashboard) and click Execution-plan in click Stream in the Analytics category. 
  2. Select Import Execution-plan and click Select Import Stream and click Next. 
  3. Type a unique name for the Execution-planStream. 
  4. Specify the execution-plan stream file by typing its full path name or clicking clicking Browse and  and navigating to the file. 
  5. In the Save Execution-plan Stream In field, specify an existing Analytics project in your workspace where you want to save the execution-planstream, or click click Create new Project to  to create a new Analytics project and save the execution-plan stream there. 
  6. Click Click Finish. The execution-plan stream is created in the execution-plan stream folder under the Analytics project you specified, and the execution-plan stream is open in the editor.

 

Creating

...

an Execution-plan

WSO2 CEP uses Execution Plans to store event processing logic. An Execution Plan is bound to an instance of the Siddhi complex event processing runtime, which is responsible for the actual processing of the events. The event processor allows users to configure multiple Execution Plans where by providing multiple isolated event processing environments per Execution Plan. A typical Execution Plan consists of a set of queries and related input and output Event Streams.Definitions of the event streams are stored in the file system as deployable artifacts in the  <CARBON _HOME>/repository/deployment/server/eventstreamsexecutionplans/ directory as .jsonsiddhiql files. More

Creating a new

...

Execution-plan

Follow these steps to create a new streamexecution-plan. Alternatively, you can import an existing streamexecution-plan.

  1. Open the Developer Studio Dashboard (click Developer Studio > Open Dashboard) and click Stream Execution-plan in the Analytics category.
  2. Select Create New StreamExecution-plan and click Next.
  3. Type a unique name for the StreamExecution-plan.
  4. Do one of the following:
    • To save the
  5. stream
    • execution-plan in an existing Analytics project in your workspace,
  6. click 
    • click Browse
  7.  and
    • and select that project.
    • To save the
  8. stream
    • execution-plan in a new Analytics project,
  9. click 
    • click Create new Project
  10.  and
    • and create the new project.
  11. Click Finish. The stream execution-plan is created in the stream execution-plan folder under the Analytics project you specified, and the stream execution-plan is open in the editor.

Importing

...

an Execution-plan

Follow these steps to import an existing stream execution-plan from a .json siddhiql file into an Analytics project. Alternatively, you can create a new streamexecution-plan.

  1. Open the Developer Studio Dashboard (click Developer Studio > Open Dashboard) and click Stream Execution-plan in the Analytics category. 
  2. Select Import StreamExecution-plan and click Next. 
  3. Type a unique name for the StreamExecution-plan. 
  4. Specify the stream execution-plan file by typing its full path name or clicking Browse and navigating to the file. 
  5. In the Save Stream Execution-plan In field, specify an existing Analytics project in your workspace where you want to save the streamexecution-plan, or click Create new Project to create a new Analytics project and save the stream execution-plan there. 
  6. Click Finish. The stream execution-plan is created in the stream execution-plan folder under the Analytics project you specified, and the stream execution-plan is open in the editor.

 

Creating a Publisher

...

  1. Open the Developer Studio Dashboard (click Developer Studio > Open Dashboard) and click Publisher in the Analytics category.
  2. Select Create New Publisher and click Next.
  3. Type a unique name for the Publisher.
  4. Do one of the following:
      • To save the publisher in an existing Analytics project in your workspace, click Browse and select that project.
      • To save the publisher in a new Analytics project, click Create new Project and create the new project.
  5. Click Finish. The publisher is created in the publisher folder under the Analytics project you specified, and the publisher is open in the editor.

Importing a Publisher 

Follow these steps to import an existing publisher from an XML file into an Analytics project. Alternatively, you can create a new publisher.

...