Type-safe, Polyvariadic Event Correlation

07/05/2019
by   Oliver Bračevac, et al.
0

The pivotal role that event correlation technology plays in todays applications has lead to the emergence of different families of event correlation approaches with a multitude of specialized correlation semantics, including computation models that support the composition and extension of different semantics. However, type-safe embeddings of extensible and composable event patterns into statically-typed general-purpose programming languages have not been systematically explored so far. Event correlation technology has often adopted well-known and intuitive notations from database queries, for which approaches to type-safe embedding do exist. However, we argue in the paper that these approaches, which are essentially descendants of the work on monadic comprehensions, are not well-suited for event correlations and, thus, cannot without further ado be reused/re-purposed for embedding event patterns. To close this gap we propose PolyJoin, a novel approach to type-safe embedding for fully polyvariadic event patterns with polymorphic correlation semantics. Our approach is based on a tagless final encoding with uncurried higher-order abstract syntax (HOAS) representation of event patterns with n variables, for arbitrary n ∈N. Thus, our embedding is defined in terms of the host language without code generation and exploits the host language type system to model and type check the type system of the pattern language. Hence, by construction it impossible to define ill-typed patterns. We show that it is possible to have a purely library-level embedding of event patterns, in the familiar join query notation, which is not restricted to monads. PolyJoin is practical, type-safe and extensible. An implementation of it in pure multicore OCaml is readily usable.

READ FULL TEXT

page 1

page 2

page 3

page 4

research
05/23/2021

OntoED: Low-resource Event Detection with Ontology Embedding

Event Detection (ED) aims to identify event trigger words from a given t...
research
03/29/2018

The process of purely event-driven programs

Using process algebra, this paper describes the formalisation of the pro...
research
03/07/2019

Composite Event Recognition for Maritime Monitoring

Maritime monitoring systems support safe shipping as they allow for the ...
research
03/07/2019

Composite Event Recognition for Maritime Monitoring: Industry Paper

Maritime monitoring systems support safe shipping as they allow for the ...
research
08/30/2017

Type Safe Redis Queries: A Case Study of Type-Level Programming in Haskell

Redis is an in-memory data structure store, often used as a database, wi...
research
04/05/2019

The Derivation of Failure Event Correlation Based on Shadowing Cross-Correlation

In this document we derive the mapping between the failure event correla...
research
12/04/2017

A Second-Order Approach to Complex Event Recognition

Complex Event Recognition (CER for short) refers to the activity of dete...

Please sign up or login with your details

Forgot password? Click here to reset