Architecture
The WSO2 CEP architecture consists of the following components:
The diagram below depicts the architecture with its components. Note that the arrows that are in purple show the event flow through the system.
Figure: Components and event flows of WSO2 CEP
Input Event Adapter
Input Event Adapter receives events that are coming to the CEP. WSO2 CEP supports the most common adapter implementations by default. For specific usecases, you can also plug custom adapters. For more information, see Working with Input Event Adapters.
Event Builder
Event builders convert the events received by Input Event Adapter (in XML, JSON, Text, Map and WSO2Event formats) to event streams. You can also configure input event mappings to support any event format. For more information, see Working with Event Builders.
Event Stream Manager
Event Stream Manager handles all event streams in the system. It is the central hub for all events. Event Stream Manager stores stream definitions in the governance registry via the DataBridge Stream Definition Store. Event Builder, Event Processor and Event Formatter components interact with Event Stream Manager to retrieve information regarding the streams. For more information, see Working with Event Streams.
Event Processor
Event Processor handles actual event processing. It is the core event processing unit of the CEP. It manages different execution plans and processes events based on logic, with the help of different Siddhi engines. Event Processor gets a set of event streams from the Event Stream Manager, processes them using Siddhi engine, and triggers new events on different event streams back to the Event Stream Manager. For more information, see Working with Execution Plans.
Event Formatter
Event Formatters convert the events of the event streams in to different formats such as XML, Map, JSON, WSO2Event and Text. They also support configurable output event mapping. For more information, see Working with Event Formatters.
Output Event Adapter
Output Event Adapter publishes events to external systems and dumps data to databases for future analysis. Like the Input Event Adapter, this component also has different adapter implementations. The most common ones are available by default in the CEP. You can implement custom adapters for specific usecases. For more information, see Working with Output Event Adapters.