[go: up one dir, main page]
More Web Proxy on the site http://driver.im/ skip to main content
article

Cooperative decoupled processes

Published: 01 September 2018 Publication History

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.

References

[1]
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).
[2]
Aldrich, J., Sunshine, J., Saini, D., & Sparks, Z. (2009). Typestate-oriented programming. In OOPSLA '09 (pp. 1015-1022). ACM.
[3]
Association NFP (2015). Codes and standards. http://www.nfpa.org/.
[4]
Bejleri, A., Aldrich, J., & Bierhoff, K. (2006). Ego: controlling the power of simplicity. In FOOL/WOOD 06.
[5]
Bejleri, A., Mezini, M., & Eugster, P. (2016). Cooperative decoupled processes: the e-calculus and linearity. In MODULARITY.
[6]
Benton, N., Cardelli, L., & Fournet, C. (2004). Modern concurrency abstractions for c#. ACM Transactions on Programming Languages and Systems, 26(5), 769-804.
[7]
Berry, G., & Boudol, G. (1992). The chemical abstract machine. Theoretical Computer Science, 96(1), 217-248.
[8]
Bidinger, P., & Stefani, J.B. (2003). The kell calculus: operational semantics and type system. In FMOODS (pp. 109-123): Springer.
[9]
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).
[10]
Chin, B., & Millstein, T. (2006). Responders: language support for interactive applications. In ECOOP.
[11]
Courtenage, S. (2002). Specifying and detecting composite events in content-based publish/subscribe systems. In ICDCS Workshops (pp. 602-610).
[12]
Crafa, S., & Padovani, L. (2015). The chemical approach to typestate-oriented programming. In OOPSLA.
[13]
Cunningham, R., & Kohler, E. (2005). Making events less slippery with eel. In HOTOS.
[14]
Deniélou, P.M., & Yoshida, N. (2011). Dynamic multirole session types. In POPL '11 (pp. 435-446).
[15]
Desai, A., Gupta, V., Jackson, E., Qadeer, S., Rajamani, S., & Zufferey, D. (2013). P: safe asynchronous event-driven programming. SIGPLAN Notices, 48(6).
[16]
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.
[17]
Fiege, L., Mezini, M., Mühl, G., & Buchmann, A.P. (2002). Engineering event-based systems with scopes. In ECOOP '02 (pp. 309-333).
[18]
Floyd, S., et al. (1997). A reliable multicast framework for light-weight sessions and application level framing. IEEE/ACM Transactions Network, 5(6).
[19]
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).
[20]
Fournet, C., & Gonthier, G. (1996). The reflexive cham and the join-calculus. In POPL (pp. 372-385).
[21]
Fournet, C., Gonthier, G., Lévy, J.J., Maranget, L., & Rémy, D. (1996). A calculus of mobile agents. In CONCUR (pp. 406-421).
[22]
Fournet, C., Laneve, C., & Maranget, L. (1997). Implicit typing 'a la ml for the join-calculus. In Concur (pp. 196-212): Springer.
[23]
Franklin, M., & Zdonik, S. (1997). A framework for scalable dissemination-based systems. SIGPLAN Notices, 32(10).
[24]
Friedman, D.P., Haynes, C.T., & Kohlbecker, E.E. (1984). Programming with continuations. In PTPE (pp. 263-274).
[25]
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).
[26]
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).
[27]
Gelernter, D. (1985). Generative communication in linda. ACM Transactions on Programming Languages and Systems, 7(1).
[28]
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.
[29]
Girard, J.Y. (1987). Linear logic. Theoretical Computer Science, 50, 1-102.
[30]
Gustafsson, A. (2005). Threads without the pain. Queue, 3(9).
[31]
Haller, P., & Cutsem, T.V. (2008). Implementing joins using extensible pattern matching. In COORDINATION.
[32]
Haller, P., & Odersky, M. (2006). Event-based programming without inversion of control. In JMLC.
[33]
Haller, P., & Odersky, M. (2009). Scala actors: unifying thread-based and event-based programming. Theoretical Computer Science, 410(2-3).
[34]
Ham, J.M.V., Salvaneschi, G., Mezini, M., & Noyé, J. (2014). Jescala: modular coordination with declarative events and joins. In MODULARITY (pp. 205-216).
[35]
Hinze, A., & Voisard, A. (2002). A parameterized algebra for event notification services. In TIME (pp. 61-63).
[36]
Hu, R., Kouzapas, D., Pernet, O., Yoshida, N., & Honda, K. (2010). Type-safe eventful sessions in java. In ECOOP.
[37]
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.
[38]
Lamport, L. (1978). Time, clocks, and the ordering of events in a distributed system. Communication of the ACM, 21(7), 558-565.
[39]
Li, P., & Zdancewic, S. (2007). Combining events and threads for scalable network services implementation and evaluation of monadic application-level concurrency primitives. In PLDI.
[40]
Ousterhout, J.K. (1996). Why threads are a bad idea (for most purposes). In Usenix (Invited talk).
[41]
Parnas, D.L. (1972). On the criteria to be used in decomposing systems into modules. Communications of the ACM, 15(12).
[42]
Pnueli, A. (1977). The temporal logic of programs. In FOCS (pp. 46-57).
[43]
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).
[44]
Schmitt, A., & Stefani, J.B. (2003). The m-calculus: a higher-order distributed process calculus. In POPL (pp. 50-61).
[45]
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).
[46]
Strom, R.E., & Yemini, S. (1986). Typestate: a programming language concept for enhancing software reliability. IEEE Transactions on Software Engineering, 12(1), 157-171.
[47]
Sunshine, J., Naden, K., Stork, S., Aldrich, J., & Tanter, É. (2011). First-class state change in plaid. In OOPSLA (pp. 713-732).
[48]
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).
[49]
Welsh, M., Culler, D.E., & Brewer, E.A. (2001). Seda: An architecture for well-conditioned, scalable internet services. In SOSP (pp. 230-243).

Cited By

View all
  • (2018)Decoupling Design Based on Power Dispatching Management Cloud Computing PlatformProceedings of the 2nd International Conference on Big Data Research10.1145/3291801.3291821(206-211)Online publication date: 27-Oct-2018

Recommendations

Comments

Please enable JavaScript to view thecomments powered by Disqus.

Information & Contributors

Information

Published In

cover image Software Quality Journal
Software Quality Journal  Volume 26, Issue 3
September 2018
326 pages

Publisher

Kluwer Academic Publishers

United States

Publication History

Published: 01 September 2018

Author Tags

  1. Aliasing
  2. Control flow
  3. Decoupling
  4. Event-driven programming
  5. Linear type system

Qualifiers

  • Article

Contributors

Other Metrics

Bibliometrics & Citations

Bibliometrics

Article Metrics

  • Downloads (Last 12 months)0
  • Downloads (Last 6 weeks)0
Reflects downloads up to 05 Jan 2025

Other Metrics

Citations

Cited By

View all
  • (2018)Decoupling Design Based on Power Dispatching Management Cloud Computing PlatformProceedings of the 2nd International Conference on Big Data Research10.1145/3291801.3291821(206-211)Online publication date: 27-Oct-2018

View Options

View options

Media

Figures

Other

Tables

Share

Share

Share this Publication link

Share on social media