Distributed Reactive Programming for Reactive Distributed Systems

Context: The term reactivity is popular in two areas of research: programming languages and distributed systems. On one hand, reactive programming is a paradigm which provides programmers with the means to declaratively write event-driven applications. On the other hand, reactive distributed systems handle client requests in a timely fashion regardless of load or failures. Inquiry: Reactive programming languages and frameworks tailored to the implementation of distributed systems have previously been proposed. However, we argue that these approaches are ill fit to implement reactive distributed systems. Approach: We analyse state of the art runtimes for distributed reactive programming and identify two key issues with regards to reactive distributed systems. They rely on single, central points of coordination and/or assume a lack of partial failures in the systems they support. Knowledge: Based on our analysis we propose a novel runtime for distributed reactive programming languages and frameworks. This runtime supports reactive distributed systems by design. Grounding: We implement a proof of concept framework for reactive distributed systems in JavaScript which builds atop our runtime. Using this framework we implement a case study application which highlights the applicability of our approach. Moreover, we benchmark our runtime against a similar approach in order to showcase its runtime properties and we prove its correctness. Importance: This work aims to bridge the gap between two kinds of reactivity: reactive distributed systems and distributed reactive programming. Current distributed reactive programming approaches do not support reactive distributed systems. Our runtime is the first to bridge this reactivity gap: it allows for reactive distributed systems to be implemented using distributed reactive programming.

[1]  Shriram Krishnamurthi,et al.  Embedding Dynamic Dataflow in a Call-by-Value Language , 2006, ESOP.

[2]  Guido Salvaneschi,et al.  We have a DREAM: distributed reactive programming with consistency guarantees , 2014, DEBS '14.

[3]  Marcos K. Aguilera,et al.  Failure detection and consensus in the crash-recovery model , 1998, Distributed Computing.

[4]  Wolfgang De Meuter,et al.  A survey on reactive programming , 2013, CSUR.

[5]  Gérard Berry,et al.  The Esterel Synchronous Programming Language: Design, Semantics, Implementation , 1992, Sci. Comput. Program..

[6]  Mira Mezini,et al.  An empirical study on program comprehension with reactive programming , 2014, SIGSOFT FSE.

[7]  T. Gautier,et al.  The Signal Synchronous Multiclock Approach to the Design of Distributed Embedded Systems , 2010, IEEE Transactions on Parallel and Distributed Systems.

[8]  Carlos Baquero,et al.  Quality-Aware Reactive Programming for the Internet of Things , 2017, FSEN.

[9]  Dominique Devriese,et al.  Multi-Tier Functional Reactive Programming for the Web , 2014, Onward!.

[10]  Stephen Chong,et al.  Asynchronous functional reactive programming for GUIs , 2013, PLDI.

[11]  Shriram Krishnamurthi,et al.  Flapjax: a programming language for Ajax applications , 2009, OOPSLA 2009.

[12]  Mira Mezini,et al.  Distributed REScala: an update algorithm for distributed reactive programming , 2014, OOPSLA 2014.

[13]  M. Frans Kaashoek,et al.  Rover: a toolkit for mobile information access , 1995, SOSP.

[14]  John K. Ousterhout,et al.  In Search of an Understandable Consensus Algorithm , 2014, USENIX ATC.

[15]  Wolfgang De Meuter,et al.  Parallel and Distributed Web Programming with Actors , 2018, Programming with Actors.

[16]  Albert Benveniste,et al.  Concurrency in Synchronous Systems , 2006, Formal Methods Syst. Des..

[17]  Costin Badica,et al.  Bringing Paxos Consensus in Multi-agent Systems , 2014, WIMS '14.

[18]  Martin Odersky,et al.  Higher-Order Reactive Programming with Incremental Lists , 2013, ECOOP.

[19]  Steven Hand,et al.  On deadlock, livelock, and forward progress , 2005 .

[20]  Wolfgang De Meuter,et al.  Loosely-Coupled Distributed Reactive Programming in Mobile Ad Hoc Networks , 2010, TOOLS.

[21]  A. Prasad Sistla,et al.  Efficient distributed recovery using message logging , 1989, PODC '89.

[22]  Roberto Ierusalimschy,et al.  Safe system-level concurrency on resource-constrained nodes , 2013, SenSys '13.

[23]  Albert Benveniste,et al.  Compositionality in Dataflow Synchronous Languages: Specification and Distributed Code Generation , 2000, Inf. Comput..

[24]  Noemi Rodriguez,et al.  A GALS Approach for Programming Distributed Interactive Multimedia Applications , 2018 .

[25]  Wolfgang De Meuter,et al.  AmbientTalk: programming responsive mobile peer-to-peer applications with actors , 2014, Comput. Lang. Syst. Struct..