com.datarpm.sigma:event-engine-model

Event Processing Engine project

License

License

Categories

Categories

Data
GroupId

GroupId

com.datarpm.sigma
ArtifactId

ArtifactId

event-engine-model
Last Version

Last Version

1.6.1
Release Date

Release Date

Type

Type

jar
Description

Description

Event Processing Engine project

Download event-engine-model

How to add to project

<!-- https://jarcasting.com/artifacts/com.datarpm.sigma/event-engine-model/ -->
<dependency>
    <groupId>com.datarpm.sigma</groupId>
    <artifactId>event-engine-model</artifactId>
    <version>1.6.1</version>
</dependency>
// https://jarcasting.com/artifacts/com.datarpm.sigma/event-engine-model/
implementation 'com.datarpm.sigma:event-engine-model:1.6.1'
// https://jarcasting.com/artifacts/com.datarpm.sigma/event-engine-model/
implementation ("com.datarpm.sigma:event-engine-model:1.6.1")
'com.datarpm.sigma:event-engine-model:jar:1.6.1'
<dependency org="com.datarpm.sigma" name="event-engine-model" rev="1.6.1">
  <artifact name="event-engine-model" type="jar" />
</dependency>
@Grapes(
@Grab(group='com.datarpm.sigma', module='event-engine-model', version='1.6.1')
)
libraryDependencies += "com.datarpm.sigma" % "event-engine-model" % "1.6.1"
[com.datarpm.sigma/event-engine-model "1.6.1"]

Dependencies

compile (11)

Group / Artifact Type Version
com.datarpm.sigma : event-engine-core jar 1.6.1
org.hibernate.ogm : hibernate-ogm-infinispan jar
org.hibernate.javax.persistence : hibernate-jpa-2.1-api jar
org.jboss.spec.javax.transaction : jboss-transaction-api_1.2_spec jar
org.hibernate.ogm : hibernate-ogm-mongodb jar
org.hibernate.ogm : hibernate-ogm-ehcache jar
org.jboss.narayana.jta : narayana-jta jar
org.hsqldb : hsqldb jar 2.4.0
com.mysema.querydsl : querydsl-jpa jar 3.7.4
org.jboss : jboss-transaction-spi jar 7.6.0.Final
log4j : log4j jar

test (1)

Group / Artifact Type Version
junit : junit jar 4.10

Project Modules

There are no modules declared in this project.

Sigma Event Engine

Quick start

Install

  1. Download event-engine-1.6-bin.tar.gz from releases page
  2. Extract
tar -xzf event-engine-1.6-bin.tar.gz
  1. Set the SIGMA_EVENTENGINE_HOME environment variable to point to extracted path
  2. Start service
cd event-engine-1.6/
./bin/eventengine-daemon.sh start

Starts websocket listener on port 8082 (ws://locahost:8082/event-stream)

Clients

Java

Using Maven:

<dependency>
    <groupId>com.datarpm.sigma</groupId>
    <artifactId>event-engine-core</artifactId>
    <version>1.6</version>
</dependency>

Generate event:

// prepare event builder
// code identifies event (action)
// example: USER_LOGGED_IN, USER_LOGGED_OUT, AUTHENTICATION_FAILURE
String code = "<EVENT_CODE_ID>";
EventBuilder eventBuilder = new EventBuilder(code);
// Set headers
// Used for event filtering
eventBuilder.addHeader("<headerKey>", "<headerValue>");
// Marks it as system event
SystemEventDetail systemEventDetails = new SystemEventDetail();
eventBuilder.generateSystemEvent(systemEventDetails);
// Event parameters
eventBuilder.addParam("<paramKey>", "<paramValue>");
eventBuilder.fireEvent();

Listen for an event:

EventMatchFilter matchFilter = new EventMatchFilter() {
  /*
   * Tests if specified eventHeader should be used for callback  
   */
  @Override
  public boolean allow(EventHeader eventHeader) {
    // Write filter logic
    return true;
  }
};

EventEngine.INSTANCE.addListner(matchFilter, new EventCallBack() {
  @Override
  public void onEvent(Event event) {
    // Do something
  }
});

Javascript

Refer to sigma-events-client-js

com.datarpm.sigma

DataRPM

Versions

Version
1.6.1
1.6