Advertisement

Reversible Choreographies via Monitoring in Erlang

  • Adrian FrancalanzaEmail author
  • Claudio Antares MezzinaEmail author
  • Emilio TuostoEmail author
Conference paper
Part of the Lecture Notes in Computer Science book series (LNCS, volume 10853)

Abstract

We render a model advocating an extension of choreographies to describe reverse computation via monitoring. More precisely, our extension imbues the communication behaviour of multi-party protocols with minimal decorations specifying the conditions triggering monitor adaptations. We show how, from these extended global descriptions, one can (i) synthesise actors implementing the normal local behaviour of the system prescribed by the global graph, but also (ii) synthesise monitors that are able to coordinate a distributed rollback when certain conditions (denoting abnormal behaviour) are met.

Notes

Acknowledgements

This work sprang up from the MSCA-IF-2017 fellowship RCADE 794405.

References

  1. 1.
    Agha, G.: Actors: A Model of Concurrent Computation in Distributed Systems. MIT Press, Cambridge (1986)Google Scholar
  2. 2.
    Armstrong, J.: Programming Erlang: Software for a Concurrent World. Pragmatic Bookshelf, Raleigh (2007)Google Scholar
  3. 3.
    Artho, C., Barringer, H., Goldberg, A., Havelund, K., Khurshid, S., Lowry, M.R., Pasareanu, C.S., Rosu, G., Sen, K., Visser, W., Washington, R.: Combining test case generation and runtime verification. TCS 336(2–3), 209–234 (2005)MathSciNetCrossRefGoogle Scholar
  4. 4.
    Bocchi, L., Chen, T.-C., Demangeon, R., Honda, K., Yoshida, N.: Monitoring networks through multiparty session types. In: Beyer, D., Boreale, M. (eds.) FMOODS/FORTE 2013. LNCS, vol. 7892, pp. 50–65. Springer, Heidelberg (2013).  https://doi.org/10.1007/978-3-642-38592-6_5CrossRefGoogle Scholar
  5. 5.
    Bocchi, L., Honda, K., Tuosto, E., Yoshida, N.: A theory of design-by-contract for distributed multiparty interactions. In: Gastin, P., Laroussinie, F. (eds.) CONCUR 2010. LNCS, vol. 6269, pp. 162–176. Springer, Heidelberg (2010).  https://doi.org/10.1007/978-3-642-15375-4_12CrossRefzbMATHGoogle Scholar
  6. 6.
    Cassar, I., Francalanza, A.: Runtime adaptation for actor systems. In: Bartocci, E., Majumdar, R. (eds.) RV 2015. LNCS, vol. 9333, pp. 38–54. Springer, Cham (2015).  https://doi.org/10.1007/978-3-319-23820-3_3CrossRefGoogle Scholar
  7. 7.
    Cassar, I., Francalanza, A.: On implementing a monitor-oriented programming framework for actor systems. In: iFM (2016)Google Scholar
  8. 8.
    Cassar, I., Francalanza, A., Mezzina, C.A., Tuosto, E.: Reliability and fault-tolerance by choreographic design. In: PrePost@iFM. EPTCS, vol. 254 (2017)Google Scholar
  9. 9.
    Cesarini, F., Thompson, S.: Erlang Programming. O’Reilly, Sebastopol (2009)zbMATHGoogle Scholar
  10. 10.
    Chen, F., Rosu, G.: Towards Monitoring-Oriented Programming: a paradigm combining specification and implementation. Electr. Notes Theor. Comput. Sci. 89(2), 108–127 (2003)CrossRefGoogle Scholar
  11. 11.
    Clarkson, M.R., Schneider, F.B.: Hyperproperties. J. Comput. Secur. 18(6), 1157–1210 (2010)CrossRefGoogle Scholar
  12. 12.
    Deniélou, P.-M., Yoshida, N.: Multiparty session types meet communicating automata. In: Seidl, H. (ed.) ESOP 2012. LNCS, vol. 7211, pp. 194–213. Springer, Heidelberg (2012).  https://doi.org/10.1007/978-3-642-28869-2_10CrossRefGoogle Scholar
  13. 13.
    Desai, A., Dreossi, T., Seshia, S.A.: Combining model checking and runtime verification for safe robotics. In: Lahiri, S., Reger, G. (eds.) RV 2017. LNCS, vol. 10548, pp. 172–189. Springer, Cham (2017).  https://doi.org/10.1007/978-3-319-67531-2_11CrossRefGoogle Scholar
  14. 14.
    Elnozahy, E.N., Alvisi, L., Wang, Y., Johnson, D.B.: A survey of rollback-recovery protocols in message-passing systems. ACM Comput. Surv. 34(3), 375–408 (2002)CrossRefGoogle Scholar
  15. 15.
    Erlang Run-Time System Application, Reference Manual Version 9.2. http://erlang.org/doc/man/erlang.html
  16. 16.
    Field, J., Varela, C.A.: Transactors: a programming model for maintaining globally consistent distributed state in unreliable environments. In: POPL 2005. ACM (2005)Google Scholar
  17. 17.
    Francalanza, A.: A theory of monitors. In: Jacobs, B., Löding, C. (eds.) FoSSaCS 2016. LNCS, vol. 9634, pp. 145–161. Springer, Heidelberg (2016).  https://doi.org/10.1007/978-3-662-49630-5_9CrossRefzbMATHGoogle Scholar
  18. 18.
    Francalanza, A., Aceto, L., Achilleos, A., Attard, D.P., Cassar, I., Della Monica, D., Ingólfsdóttir, A.: A foundation for runtime monitoring. In: Lahiri, S., Reger, G. (eds.) RV 2017. LNCS, vol. 10548, pp. 8–29. Springer, Cham (2017).  https://doi.org/10.1007/978-3-319-67531-2_2CrossRefGoogle Scholar
  19. 19.
    Gray, J., Reuter, A.: Transaction Processing: Concepts and Techniques. Morgan Kaufmann, San Mateo (1993)zbMATHGoogle Scholar
  20. 20.
    Guanciale, R., Tuosto, E.: An abstract semantics of the global view of choreographies. In: ICE (2016)Google Scholar
  21. 21.
    Hewitt, C., Bishop, P., Steiger, R.: A universal modular ACTOR formalism for artificial intelligence. In: IJCAI. Morgan Kaufmann Publishers Inc. (1973)Google Scholar
  22. 22.
    Honda, K., Yoshida, N., Carbone, M.: Multiparty asynchronous session types. J. ACM 63(1), 1–67 (2016). Extended version of a paper presented at POPL 2008MathSciNetCrossRefGoogle Scholar
  23. 23.
    Kejstová, K., Ročkai, P., Barnat, J.: From model checking to runtime verification and back. In: Lahiri, S., Reger, G. (eds.) RV 2017. LNCS, vol. 10548, pp. 225–240. Springer, Cham (2017).  https://doi.org/10.1007/978-3-319-67531-2_14CrossRefGoogle Scholar
  24. 24.
    Lanese, I., Mezzina, C.A., Stefani, J.-B.: Controlled reversibility and compensations. In: Glück, R., Yokoyama, T. (eds.) RC 2012. LNCS, vol. 7581, pp. 233–240. Springer, Heidelberg (2013).  https://doi.org/10.1007/978-3-642-36315-3_19CrossRefGoogle Scholar
  25. 25.
    Meredith, P.O., Jin, D., Griffith, D., Chen, F., Roşu, G.: An overview of the MOP runtime verification framework. STTT 14(3), 249–289 (2012)CrossRefGoogle Scholar
  26. 26.
    Mezzina, C.A., Pérez, J.A.: Causally consistent reversible choreographies: a monitors-as-memories approach. In: PPDP (2017)Google Scholar
  27. 27.
    Mezzina, C.A., Pérez, J.A.: Reversibility in session-based concurrency: a fresh look. J. Log. Algebr. Meth. Program. 90, 2–30 (2017)MathSciNetCrossRefGoogle Scholar
  28. 28.
    Neykova, R., Yoshida, N.: Let it recover: multiparty protocol-induced recovery. In: CC. ACM (2017)Google Scholar
  29. 29.
    Nishida, N., Palacios, A., Vidal, G.: A reversible semantics for Erlang. In: Hermenegildo, M.V., Lopez-Garcia, P. (eds.) LOPSTR 2016. LNCS, vol. 10184, pp. 259–274. Springer, Cham (2017).  https://doi.org/10.1007/978-3-319-63139-4_15CrossRefGoogle Scholar
  30. 30.
    Perumalla, K.: Introduction to Reversible Computing. Chapman & Hall/CRC Computational Science. Taylor & Francis, Hoboken (2013)CrossRefGoogle Scholar
  31. 31.
    Phillips, I., Ulidowski, I., Yuen, S.: A reversible process calculus and the modelling of the ERK signalling pathway. In: Glück, R., Yokoyama, T. (eds.) RC 2012. LNCS, vol. 7581, pp. 218–232. Springer, Heidelberg (2013).  https://doi.org/10.1007/978-3-642-36315-3_18CrossRefzbMATHGoogle Scholar
  32. 32.
    Tuosto, E., Guanciale, R.: Semantics of global view of choreographies. J. Log. Algebr. Meth. Program. 95, 17–40 (2018)MathSciNetCrossRefGoogle Scholar

Copyright information

© IFIP International Federation for Information Processing 2018

Authors and Affiliations

  1. 1.University of MaltaMsidaMalta
  2. 2.IMT Advanced Studies LuccaLuccaItaly
  3. 3.University of LeicesterLeicesterUK

Personalised recommendations