Tackling the awkward squad for reactive programming: the actor-reactor model

In his famous paper entitled "Tackling the Awkward Squad", Peyton Jones studies how features that traditionally did not fit in the functional programming paradigm can be added to a functional language via careful language design (e.g. using monads), instead of allowing programmers to sprinkle around impure expressions and ad-hoc library calls, thereby turning the entire program into a non-functional program. Similarly, in this paper, we identify a number of code characteristics that do not map onto the reactive programming paradigm but that are present in many real life reactive programs. We propose a novel Actor-Reactor model that can serve as the basis for future language designs that allow a programmer to use the awkward squad without making the reactive parts of the program accidentally non-reactive.

[1]  Olivier Tardieu,et al.  Stream Processing with a Spreadsheet , 2014, ECOOP.

[2]  Benjamin Grégoire,et al.  Jasmin: High-Assurance and High-Speed Cryptography , 2017, CCS.

[3]  Raymond Roestenburg,et al.  Akka in Action , 2016 .

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

[5]  Joeri De Koster,et al.  43 Years of Actors: a Taxonomy of Actor Models and Their Key Properties , 2016, AGERE!@SPLASH.

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

[7]  Manuel Serrano,et al.  Hiphop.js: a language to orchestrate web applications , 2018, SAC.

[8]  Paul Hudak,et al.  Real-time FRP , 2001, ICFP '01.

[9]  Sam Tobin-Hochstadt,et al.  Size-change termination as a contract: dynamically and statically enforcing termination for higher-order programs , 2018, PLDI.

[10]  Andreas Podelski,et al.  Termination proofs for systems code , 2006, PLDI '06.

[11]  Mitchell Wand,et al.  Essentials of programming languages , 2008 .

[12]  Paul Le Guernic,et al.  SIGNAL: A declarative language for synchronous programming of real-time systems , 1987, FPCA.

[13]  Manuel Serrano,et al.  Hop and HipHop: Multitier Web Orchestration , 2013, ICDCIT.

[14]  Jonathan Edwards,et al.  Coherent reaction , 2009, OOPSLA Companion.

[15]  Shriram Krishnamurthi,et al.  Crossing State Lines: Adapting Object-Oriented Frameworks to Functional Reactive Languages , 2006, FLOPS.

[16]  Frank S. de Boer,et al.  A Survey of Active Object Languages , 2017, ACM Comput. Surv..

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

[18]  Mira Mezini,et al.  REScala: bridging between object-oriented and functional style in reactive applications , 2014, MODULARITY.

[19]  Roberto Ierusalimschy,et al.  The Design and Implementation of the Synchronous Language CÉU , 2017, ACM Trans. Embed. Comput. Syst..

[20]  Akinori Yonezawa,et al.  Object-oriented concurrent programming ABCL/1 , 1986, OOPLSA '86.

[21]  Nicolas Halbwachs,et al.  Programming and Verifying Real-Time Systems by Means of the Synchronous Data-Flow Language LUSTRE , 1992, IEEE Trans. Software Eng..

[22]  Gerald J. Sussman,et al.  Structure and Interpretation of Computer Programs, Second Edition , 1996 .

[23]  Deian Stefan,et al.  FaCT: A Flexible, Constant-Time Programming Language , 2017, 2017 IEEE Cybersecurity Development (SecDev).

[24]  Mira Mezini,et al.  Thread-safe reactive programming , 2018, Proc. ACM Program. Lang..

[25]  Gérard Berry,et al.  Real Time Programming: Special Purpose or General Purpose Languages , 1989, IFIP Congress.

[26]  Bonnie Eisenman,et al.  Learning React Native: Building Native Mobile Apps with JavaScript , 2016 .

[27]  Simon Peyton Jones,et al.  Tackling the Awkward Squad: monadic input/output, concurrency, exceptions, and foreign-language calls in Haskell , 2005 .

[28]  Miran Lipovaca,et al.  Learn You a Haskell for Great Good!: A Beginner's Guide , 2011 .

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

[30]  David Robson,et al.  Smalltalk-80: The Language and Its Implementation , 1983 .

[31]  Robert de Simone,et al.  The Synchronous Hypothesis and Synchronous Languages , 2005, Embedded Systems Handbook.

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

[33]  Mira Mezini,et al.  On the Positive Effect of Reactive Programming on Software Comprehension: An Empirical Study , 2017, IEEE Transactions on Software Engineering.

[34]  Derick Wood,et al.  Theory of computation , 1986 .

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

[36]  D. Turner Total Functional Programming , 2004, J. Univers. Comput. Sci..

[37]  Martin Odersky,et al.  Deprecating the Observer Pattern with Scala.React , 2012 .

[38]  Wolfgang De Meuter,et al.  Composable higher-order reactors as the basis for a live reactive programming environment , 2018, REBLS@SPLASH.