2019
DOI: 10.1145/3290342
|View full text |Cite
|
Sign up to set email alerts
|

Distributed programming using role-parametric session types in go: statically-typed endpoint APIs for dynamically-instantiated communication structures

Abstract: This paper presents a framework for the static specification and safe programming of message passing protocols where the number and kinds of participants are dynamically instantiated. We develop the first theory of distributed multiparty session types (MPST) to support parameterised protocols with indexed rolesÐour framework statically infers the different kinds of participants induced by a protocol definition as role variants, and produces decoupled endpoint projections of the protocol onto each variant. This… Show more

Help me understand this report

Search citation statements

Order By: Relevance

Paper Sections

Select...
3
1

Citation Types

0
71
0

Year Published

2019
2019
2020
2020

Publication Types

Select...
5
3
1

Relationship

5
4

Authors

Journals

citations
Cited by 47 publications
(71 citation statements)
references
References 34 publications
0
71
0
Order By: Relevance
“…Based on the communication API shown in this section, including Offer and DelegNew, we show an implementation of tak client in Figure 5, with a timeout. Line 1 sends the three arguments (16,3,2) to the server, and Line 2 freshly creates a channel cancelCh and send it to the server using bound output DelegNew, for later termination request. Lines 3-4 arranges an output of a termination request in 10 seconds (10000 milliseconds).…”
Section: A Tak Client Examplementioning
confidence: 99%
See 1 more Smart Citation
“…Based on the communication API shown in this section, including Offer and DelegNew, we show an implementation of tak client in Figure 5, with a timeout. Line 1 sends the three arguments (16,3,2) to the server, and Line 2 freshly creates a channel cancelCh and send it to the server using bound output DelegNew, for later termination request. Lines 3-4 arranges an output of a termination request in 10 seconds (10000 milliseconds).…”
Section: A Tak Client Examplementioning
confidence: 99%
“…1 var cliCh = prot.ForkThread(srvCh => { 2 var srvCh2 = 3 srvCh.Receive(out int x, out int y, out int z) 4 .DelegRecv(out var cancelCh); 5 cancelCh.ReceiveAsync(out Task cancel).Close(); srvCh2.SelectRight().Close(); // if cancelled 14 } 15 int Tak(int a, int b, int c) { 16 if (cancel.IsCompleted) 17 throw new OperationCanceledException(); 18 return a <= b ? b : 19 Tak(Tak(a-1,b,c),Tak(b-1,c,a),Tak(c-1,a,b)); 20 }}); Figure 1: A Cancellable tak [20] Implementation in SessionC# From the above, C# compiler can statically derive both the client and the server's session type which is dual to each other, ensuring the safe interaction between the two peers.…”
mentioning
confidence: 99%
“…Our protocols-as-types are related to session types [11,26,27,69], and their combination with value-dependent and indexed types [10,14,[75][76][77]; session types have inspired various implementations [3], also in Scala [65][66][67][68]. Our theory has a different design, yielding different features.…”
Section: Conclusion and Related Workmentioning
confidence: 99%
“…Pabble [26] generates C/MPI skeleton code from parameterised Scribble for correct-by-construction role-parameterised MPI parallel programming but do not use types to check for conformance. The approach was revisited in [4] using a new distributed formalisation of parameterised Scribble and applied to Go in the Scribble-Go toolchain, with support for TCP and in-process shared memory transport. StMungo [17,18] uses Scribble to generate typestate definitions for static type checking of communication protocols in Java.…”
Section: Related Workmentioning
confidence: 99%