Skip to main content
Erschienen in: Software Quality Journal 3/2018

22.06.2017

Cooperative decoupled processes

verfasst von: Andi Bejleri, Mira Mezini, Patrick Eugster, Elton Domnori

Erschienen in: Software Quality Journal | Ausgabe 3/2018

Einloggen

Aktivieren Sie unsere intelligente Suche, um passende Fachinhalte oder Patente zu finden.

search-config
loading …

Abstract

Event-driven programming has become a major paradigm in developing concurrent, distributed systems. Its benefits are often informally captured by the key tenet of “decoupling,” a notion which roughly captures the ability of processes to join and leave (or fail) applications dynamically, and to be developed by independent parties. Programming models for event-driven programming either make it hard to globally reason about control flow, thus hampering sound execution, or sacrifice decoupling to aid in reasoning about control flow. This work fills the gap by introducing a programming model—dubbed cooperative decoupled processes—that achieves both decoupling and global reasoning about control flow. We introduce this programming model through an event calculus, loosely inspired by the Join calculus, that enables reasoning about cooperative decoupled processes through the concepts of pre- and postconditions. A linear type system controls aliasing of events to avoid a break of control flow and thus safe exchange of shared events. Fundamental properties of the type system such as subject reduction, migration safety, and progress are established.

Sie haben noch keine Lizenz? Dann Informieren Sie sich jetzt über unsere Produkte:

Springer Professional "Wirtschaft"

Online-Abonnement

Mit Springer Professional "Wirtschaft" erhalten Sie Zugriff auf:

  • über 67.000 Bücher
  • über 340 Zeitschriften

aus folgenden Fachgebieten:

  • Bauwesen + Immobilien
  • Business IT + Informatik
  • Finance + Banking
  • Management + Führung
  • Marketing + Vertrieb
  • Versicherung + Risiko




Jetzt Wissensvorsprung sichern!

Springer Professional "Wirtschaft+Technik"

Online-Abonnement

Mit Springer Professional "Wirtschaft+Technik" erhalten Sie Zugriff auf:

  • über 102.000 Bücher
  • über 537 Zeitschriften

aus folgenden Fachgebieten:

  • Automobil + Motoren
  • Bauwesen + Immobilien
  • Business IT + Informatik
  • Elektrotechnik + Elektronik
  • Energie + Nachhaltigkeit
  • Finance + Banking
  • Management + Führung
  • Marketing + Vertrieb
  • Maschinenbau + Werkstoffe
  • Versicherung + Risiko

Jetzt Wissensvorsprung sichern!

Springer Professional "Technik"

Online-Abonnement

Mit Springer Professional "Technik" erhalten Sie Zugriff auf:

  • über 67.000 Bücher
  • über 390 Zeitschriften

aus folgenden Fachgebieten:

  • Automobil + Motoren
  • Bauwesen + Immobilien
  • Business IT + Informatik
  • Elektrotechnik + Elektronik
  • Energie + Nachhaltigkeit
  • Maschinenbau + Werkstoffe




 

Jetzt Wissensvorsprung sichern!

Anhänge
Nur mit Berechtigung zugänglich
Fußnoten
1
The manual stack is modeled as in Adya et al. (2002).
 
2
For presentation reasons without affecting the correctness of the operational and static semantics, we write M 2 instead of writing l 1 & & l n . This style is similar to the reduction rule in the Join calculus of Fournet and Gonthier (1996).
 
3
This is the only handler that can take place. The suppression handlers do not take place given the presence of https://static-content.springer.com/image/art%3A10.1007%2Fs11219-017-9366-6/MediaObjects/11219_2017_9366_Fighe_HTML.gif and https://static-content.springer.com/image/art%3A10.1007%2Fs11219-017-9366-6/MediaObjects/11219_2017_9366_Fighf_HTML.gif in the site. The event describing a precondition guarding each handler is not present, prohibiting an arbitrary order of handler occurrences.
 
Literatur
Zurück zum Zitat Adya, A., Howell, J., Theimer, M., Bolosky, W.J., & Douceur, J.R. (2002). Cooperative task management without manual stack management. In USENIX (pp. 289–302). Adya, A., Howell, J., Theimer, M., Bolosky, W.J., & Douceur, J.R. (2002). Cooperative task management without manual stack management. In USENIX (pp. 289–302).
Zurück zum Zitat Aldrich, J., Sunshine, J., Saini, D., & Sparks, Z. (2009). Typestate-oriented programming. In OOPSLA ’09 (pp. 1015–1022). ACM. Aldrich, J., Sunshine, J., Saini, D., & Sparks, Z. (2009). Typestate-oriented programming. In OOPSLA ’09 (pp. 1015–1022). ACM.
Zurück zum Zitat Bejleri, A., Aldrich, J., & Bierhoff, K. (2006). Ego: controlling the power of simplicity. In FOOL/WOOD 06. Bejleri, A., Aldrich, J., & Bierhoff, K. (2006). Ego: controlling the power of simplicity. In FOOL/WOOD 06.
Zurück zum Zitat Bejleri, A., Mezini, M., & Eugster, P. (2016). Cooperative decoupled processes: the e-calculus and linearity. In MODULARITY. Bejleri, A., Mezini, M., & Eugster, P. (2016). Cooperative decoupled processes: the e-calculus and linearity. In MODULARITY.
Zurück zum Zitat Benton, N., Cardelli, L., & Fournet, C. (2004). Modern concurrency abstractions for c#. ACM Transactions on Programming Languages and Systems, 26(5), 769–804.CrossRefMATH Benton, N., Cardelli, L., & Fournet, C. (2004). Modern concurrency abstractions for c#. ACM Transactions on Programming Languages and Systems, 26(5), 769–804.CrossRefMATH
Zurück zum Zitat Bidinger, P., & Stefani, J.B. (2003). The kell calculus: operational semantics and type system. In FMOODS (pp. 109–123): Springer. Bidinger, P., & Stefani, J.B. (2003). The kell calculus: operational semantics and type system. In FMOODS (pp. 109–123): Springer.
Zurück zum Zitat Bolosky, W.J., & et al (2000). Feasibility of a serverless distributed file system deployed on an existing set of desktop pcs. In SIGMETRICS ’00 (pp. 34–43). Bolosky, W.J., & et al (2000). Feasibility of a serverless distributed file system deployed on an existing set of desktop pcs. In SIGMETRICS ’00 (pp. 34–43).
Zurück zum Zitat Chin, B., & Millstein, T. (2006). Responders: language support for interactive applications. In ECOOP. Chin, B., & Millstein, T. (2006). Responders: language support for interactive applications. In ECOOP.
Zurück zum Zitat Courtenage, S. (2002). Specifying and detecting composite events in content-based publish/subscribe systems. In ICDCS Workshops (pp. 602–610). Courtenage, S. (2002). Specifying and detecting composite events in content-based publish/subscribe systems. In ICDCS Workshops (pp. 602–610).
Zurück zum Zitat Crafa, S., & Padovani, L. (2015). The chemical approach to typestate-oriented programming. In OOPSLA. Crafa, S., & Padovani, L. (2015). The chemical approach to typestate-oriented programming. In OOPSLA.
Zurück zum Zitat Cunningham, R., & Kohler, E. (2005). Making events less slippery with eel. In HOTOS. Cunningham, R., & Kohler, E. (2005). Making events less slippery with eel. In HOTOS.
Zurück zum Zitat Deniélou, P.M., & Yoshida, N. (2011). Dynamic multirole session types. In POPL ’11 (pp. 435–446). Deniélou, P.M., & Yoshida, N. (2011). Dynamic multirole session types. In POPL ’11 (pp. 435–446).
Zurück zum Zitat Desai, A., Gupta, V., Jackson, E., Qadeer, S., Rajamani, S., & Zufferey, D. (2013). P: safe asynchronous event-driven programming. SIGPLAN Notices, 48(6). Desai, A., Gupta, V., Jackson, E., Qadeer, S., Rajamani, S., & Zufferey, D. (2013). P: safe asynchronous event-driven programming. SIGPLAN Notices, 48(6).
Zurück zum Zitat Eugster, P.T., Felber, P.A., Guerraoui, R., & Kermarrec, A.M. (2003). The many faces of publish/subscribe. ACM Computing Surveys, 35(2), 114–131.CrossRef Eugster, P.T., Felber, P.A., Guerraoui, R., & Kermarrec, A.M. (2003). The many faces of publish/subscribe. ACM Computing Surveys, 35(2), 114–131.CrossRef
Zurück zum Zitat Fiege, L., Mezini, M., Mühl, G., & Buchmann, A.P. (2002). Engineering event-based systems with scopes. In ECOOP ’02 (pp. 309–333). Fiege, L., Mezini, M., Mühl, G., & Buchmann, A.P. (2002). Engineering event-based systems with scopes. In ECOOP ’02 (pp. 309–333).
Zurück zum Zitat Floyd, S., & et al. (1997). A reliable multicast framework for light-weight sessions and application level framing. IEEE/ACM Transactions Network, 5(6). Floyd, S., & et al. (1997). A reliable multicast framework for light-weight sessions and application level framing. IEEE/ACM Transactions Network, 5(6).
Zurück zum Zitat Foltzer, A., Kulkarni, A., Swords, R., Sasidharan, S., Jiang, E., & Newton, R. (2012). A meta-scheduler for the par-monad: Composable scheduling for the heterogeneous cloud. SIGPLAN Notices, 47(9). Foltzer, A., Kulkarni, A., Swords, R., Sasidharan, S., Jiang, E., & Newton, R. (2012). A meta-scheduler for the par-monad: Composable scheduling for the heterogeneous cloud. SIGPLAN Notices, 47(9).
Zurück zum Zitat Fournet, C., & Gonthier, G. (1996). The reflexive cham and the join-calculus. In POPL (pp. 372–385). Fournet, C., & Gonthier, G. (1996). The reflexive cham and the join-calculus. In POPL (pp. 372–385).
Zurück zum Zitat Fournet, C., Gonthier, G., Lévy, J.J., Maranget, L., & Rémy, D. (1996). A calculus of mobile agents. In CONCUR (pp. 406–421). Fournet, C., Gonthier, G., Lévy, J.J., Maranget, L., & Rémy, D. (1996). A calculus of mobile agents. In CONCUR (pp. 406–421).
Zurück zum Zitat Fournet, C., Laneve, C., & Maranget, L. (1997). Implicit typing ‘a la ml for the join-calculus. In Concur (pp. 196–212): Springer. Fournet, C., Laneve, C., & Maranget, L. (1997). Implicit typing ‘a la ml for the join-calculus. In Concur (pp. 196–212): Springer.
Zurück zum Zitat Franklin, M., & Zdonik, S. (1997). A framework for scalable dissemination-based systems. SIGPLAN Notices, 32(10). Franklin, M., & Zdonik, S. (1997). A framework for scalable dissemination-based systems. SIGPLAN Notices, 32(10).
Zurück zum Zitat Friedman, D.P., Haynes, C.T., & Kohlbecker, E.E. (1984). Programming with continuations. In PTPE (pp. 263–274). Friedman, D.P., Haynes, C.T., & Kohlbecker, E.E. (1984). Programming with continuations. In PTPE (pp. 263–274).
Zurück zum Zitat Garcia, J., Popescu, D., Safi, G., Halfond, W., & Medvidovic, N. (2013). Identifying message flow in distributed event-based systems. In ESEC/FSE (pp. 367–377). Garcia, J., Popescu, D., Safi, G., Halfond, W., & Medvidovic, N. (2013). Identifying message flow in distributed event-based systems. In ESEC/FSE (pp. 367–377).
Zurück zum Zitat Gasiunas, V., Satabin, L., Mezini, M., Nez, A.N., & Noyé, J. (2011). EScala: modular event-driven object interactions in scala. In AOSD (pp. 227–240). Gasiunas, V., Satabin, L., Mezini, M., Nez, A.N., & Noyé, J. (2011). EScala: modular event-driven object interactions in scala. In AOSD (pp. 227–240).
Zurück zum Zitat Gelernter, D. (1985). Generative communication in linda. ACM Transactions on Programming Languages and Systems, 7(1). Gelernter, D. (1985). Generative communication in linda. ACM Transactions on Programming Languages and Systems, 7(1).
Zurück zum Zitat Germain, F., Lacoste, M., & Stefani, J.B. (2002). An abstract machine for a higher-order distributed process calculus. Electronic Notes in Theoretical Computer Science, 66(3), 145–169.CrossRef Germain, F., Lacoste, M., & Stefani, J.B. (2002). An abstract machine for a higher-order distributed process calculus. Electronic Notes in Theoretical Computer Science, 66(3), 145–169.CrossRef
Zurück zum Zitat Gustafsson, A. (2005). Threads without the pain. Queue, 3(9). Gustafsson, A. (2005). Threads without the pain. Queue, 3(9).
Zurück zum Zitat Haller, P., & Cutsem, T.V. (2008). Implementing joins using extensible pattern matching. In COORDINATION. Haller, P., & Cutsem, T.V. (2008). Implementing joins using extensible pattern matching. In COORDINATION.
Zurück zum Zitat Haller, P., & Odersky, M. (2006). Event-based programming without inversion of control. In JMLC. Haller, P., & Odersky, M. (2006). Event-based programming without inversion of control. In JMLC.
Zurück zum Zitat Haller, P., & Odersky, M. (2009). Scala actors: unifying thread-based and event-based programming. Theoretical Computer Science, 410(2–3). Haller, P., & Odersky, M. (2009). Scala actors: unifying thread-based and event-based programming. Theoretical Computer Science, 410(2–3).
Zurück zum Zitat Ham, J.M.V., Salvaneschi, G., Mezini, M., & Noyé, J. (2014). Jescala: modular coordination with declarative events and joins. In MODULARITY (pp. 205–216). Ham, J.M.V., Salvaneschi, G., Mezini, M., & Noyé, J. (2014). Jescala: modular coordination with declarative events and joins. In MODULARITY (pp. 205–216).
Zurück zum Zitat Hinze, A., & Voisard, A. (2002). A parameterized algebra for event notification services. In TIME (pp. 61–63). Hinze, A., & Voisard, A. (2002). A parameterized algebra for event notification services. In TIME (pp. 61–63).
Zurück zum Zitat Hu, R., Kouzapas, D., Pernet, O., Yoshida, N., & Honda, K. (2010). Type-safe eventful sessions in java. In ECOOP. Hu, R., Kouzapas, D., Pernet, O., Yoshida, N., & Honda, K. (2010). Type-safe eventful sessions in java. In ECOOP.
Zurück zum Zitat Kobayashi, N., Pierce, B.C., & Turner, D.N. (1999). Linearity and the pi-calculus. ACM Transactions on Programming Languages and Systems, 21(5), 914–947.CrossRef Kobayashi, N., Pierce, B.C., & Turner, D.N. (1999). Linearity and the pi-calculus. ACM Transactions on Programming Languages and Systems, 21(5), 914–947.CrossRef
Zurück zum Zitat Lamport, L. (1978). Time, clocks, and the ordering of events in a distributed system. Communication of the ACM, 21(7), 558–565.CrossRefMATH Lamport, L. (1978). Time, clocks, and the ordering of events in a distributed system. Communication of the ACM, 21(7), 558–565.CrossRefMATH
Zurück zum Zitat Li, P., & Zdancewic, S. (2007). Combining events and threads for scalable network services implementation and evaluation of monadic application-level concurrency primitives. In PLDI. Li, P., & Zdancewic, S. (2007). Combining events and threads for scalable network services implementation and evaluation of monadic application-level concurrency primitives. In PLDI.
Zurück zum Zitat Ousterhout, J.K. (1996). Why threads are a bad idea (for most purposes), Usenix (Invited talk). Ousterhout, J.K. (1996). Why threads are a bad idea (for most purposes), Usenix (Invited talk).
Zurück zum Zitat Parnas, D.L. (1972). On the criteria to be used in decomposing systems into modules. Communications of the ACM. In 15(12). Parnas, D.L. (1972). On the criteria to be used in decomposing systems into modules. Communications of the ACM. In 15(12).
Zurück zum Zitat Pnueli, A. (1977). The temporal logic of programs, FOCS (pp. 46–57). Pnueli, A. (1977). The temporal logic of programs, FOCS (pp. 46–57).
Zurück zum Zitat Sánchez, C., Sankaranarayanan, S., Sipma, H., Zhang, T., Dill, D.L., & Manna, Z. (2003). Event correlation: language and semantics. In EMSOFT (pp. 323–339). Sánchez, C., Sankaranarayanan, S., Sipma, H., Zhang, T., Dill, D.L., & Manna, Z. (2003). Event correlation: language and semantics. In EMSOFT (pp. 323–339).
Zurück zum Zitat Schmitt, A., & Stefani, J.B. (2003). The m-calculus: a higher-order distributed process calculus, POPL (pp. 50–61). Schmitt, A., & Stefani, J.B. (2003). The m-calculus: a higher-order distributed process calculus, POPL (pp. 50–61).
Zurück zum Zitat Shih, E., Bahl, P., & Sinclair, M.J. (2002). Wake on wireless: an event driven energy saving strategy for battery operated devices. In MobiCom ’02 (pp. 160–171). Shih, E., Bahl, P., & Sinclair, M.J. (2002). Wake on wireless: an event driven energy saving strategy for battery operated devices. In MobiCom ’02 (pp. 160–171).
Zurück zum Zitat Strom, R.E., & Yemini, S. (1986). Typestate: a programming language concept for enhancing software reliability. IEEE Transactions on Software Engineering, 12(1), 157–171.CrossRefMATH Strom, R.E., & Yemini, S. (1986). Typestate: a programming language concept for enhancing software reliability. IEEE Transactions on Software Engineering, 12(1), 157–171.CrossRefMATH
Zurück zum Zitat Sunshine, J., Naden, K., Stork, S., Aldrich, J., & Tanter, É. (2011). First-class state change in plaid. In OOPSLA (pp. 713–732). Sunshine, J., Naden, K., Stork, S., Aldrich, J., & Tanter, É. (2011). First-class state change in plaid. In OOPSLA (pp. 713–732).
Zurück zum Zitat von Behren, J.R., Condit, J., & Brewer, E.A. (2003). Why events are a bad idea (for high-concurrency servers). In HotOS (pp. 19–24). von Behren, J.R., Condit, J., & Brewer, E.A. (2003). Why events are a bad idea (for high-concurrency servers). In HotOS (pp. 19–24).
Zurück zum Zitat Welsh, M., Culler, D.E., & Brewer, E.A. (2001). Seda: An architecture for well-conditioned, scalable internet services. In SOSP (pp. 230–243). Welsh, M., Culler, D.E., & Brewer, E.A. (2001). Seda: An architecture for well-conditioned, scalable internet services. In SOSP (pp. 230–243).
Metadaten
Titel
Cooperative decoupled processes
verfasst von
Andi Bejleri
Mira Mezini
Patrick Eugster
Elton Domnori
Publikationsdatum
22.06.2017
Verlag
Springer US
Erschienen in
Software Quality Journal / Ausgabe 3/2018
Print ISSN: 0963-9314
Elektronische ISSN: 1573-1367
DOI
https://doi.org/10.1007/s11219-017-9366-6

Weitere Artikel der Ausgabe 3/2018

Software Quality Journal 3/2018 Zur Ausgabe

EditorialNotes

In this issue