Abstract
This is a tutorial on using Scribble [9], a toolchain based on multiparty session types [1, 4], for distributed programming in Java. The methodology is based on the generation of protocol-specific Endpoint APIs from Scribble specifications [6]. We start with a brief recap of TCP network programming using standard Java APIs, and their limitations with regards to safety assurances. The main tutorial content is an overview of the key stages of the Scribble toolchain, from global protocol specification, through Endpoint API generation, to Java endpoint implementation, with examples. We discuss the hybrid form of session safety promoted by the Endpoint API generation approach. We then consider Scribble specifications and implementations of HTTP as a real-world use case. Finally, we demonstrate some further Scribble features that leverage Endpoint API generation to safely support more advanced communication patterns.
Original language | English |
---|---|
Title of host publication | Behavioural Types |
Subtitle of host publication | from Theory to Tools English |
Publisher | River Publishers |
Pages | 287-308 |
Number of pages | 22 |
ISBN (Electronic) | 9788793519817 |
ISBN (Print) | 9788793519824 |
Publication status | Published - 31 Jul 2017 |
Externally published | Yes |