Monitoring distributed systems with distributed polyLarva

PolyLarva is a language-agnostic runtime verification tool, which converts a PolyLarvaScript into a monitor for a given system. While an implementation for PolyLarva exists, the language and its compilation have not been formalised. We therefore present a formal implementation-independent model which describes the behaviour of PolyLarvaScript, comprising of the μLarvaScript grammar and of a set of operational semantics. This allows us to prove important properties, such as determinism, and also enables us to reason about ways of re-designing the tool in a more scalable way. We also present a collection of denotational mappings for μLarvaScript converting the constructs of our grammar into constructs of a formal actor-based model, thus providing an Actor semantics for μLarvaScript. We are also able to prove certain correctness properties of the denotational translation such as that the denoted Actors behave in a way which corresponds to the behaviour described by our implementation-independent model. We finally present DistPolyLarva, a prototype implementation of the distributed PolyLarva tool, which implements the new actor-based semantics over a language that can natively handle distribution and concurrency called Erlang.