MobilityReadingGroup

π-calculus, Session Types research at the University of Oxford

Designing Asynchronous Multiparty Protocols With Crash Stop Failures
Adam D. BARWELL , Ping HOU , Nobuko YOSHIDA , Fangyi ZHOU
European Conference on Object Oriented Programming (ECOOP). p. 1:1 - 1:30

Session types provide a typing discipline for message-passing systems. However, most session type approaches assume an ideal world: one in which everything is reliable and without failures. Yet this is in stark contrast with distributed systems in the real world. To address this limitation, we introduce Teatrino, a code generation toolchain that utilises asynchronous multiparty session types (MPST) with crash-stop semantics to support failure handling protocols.

We augment asynchronous MPST and processes with crash handling branches. Our approach requires no user-level syntax extensions for global types and features a formalisation of global semantics, which captures complex behaviours induced by crashed/crash handling processes. The sound and complete correspondence between global and local type semantics guarantees deadlock-freedom, protocol conformance, and liveness of typed processes in the presence of crashes.

Our theory is implemented in the toolchain Teatrino, which provides correctness by construction. Teatrino extends the Scibble multiparty protocol language to generate protocol-conforming Scala code, using the Effpi concurrent programming library. In Teatrino, both Scribble and Effpi are extended to support crash-stop behaviour. We demonstrate the feasibility of our methodology and evaluate Teatrino with examples extended from both session type and distributed systems literature.

@inproceedings{BHYZ2023,
  author = {Adam D. Barwell and Ping Hou and Nobuko Yoshida and Fangyi Zhou},
  title = {{Designing Asynchronous Multiparty Protocols With Crash Stop Failures}},
  booktitle = {European Conference on Object Oriented Programming},
  volume = {263},
  pages = {1:1--1:30},
  year = 2023
}
@inproceedings{BHYZ2023,
  author = {Adam D. Barwell and Ping Hou and Nobuko Yoshida and Fangyi Zhou},
  title = {{Designing Asynchronous Multiparty Protocols With Crash Stop Failures}},
  booktitle = {European Conference on Object Oriented Programming},
  volume = {263},
  pages = {1:1--1:30},
  doi = "10.4230/LIPIcs.ECOOP.2023.1",
  year = 2023
}