Multiparty session types are designed to abstractly capture the structure of communication protocols and verify behavioural properties. One important such property is progress, i.e., the absence of deadlock. Distributed algorithms often resemble multiparty communication protocols. But proving their properties, in particular termination that is closely related to progress, can be elaborate. Since distributed algorithms are often designed to cope with faults, a first step towards using session types to verify distributed algorithms is to integrate fault-tolerance. We extend multiparty session types to cope with system failures such as unreliable communication and process crashes. Moreover, we augment the semantics of processes by failure patterns that can be used to represent system requirements (as, e.g., failure detectors). To illustrate our approach we analyse a variant of the well-known rotating coordinator algorithm by Chandra and Toueg.
翻译:多参与方会话类型旨在抽象地刻画通信协议的结构并验证行为性质,其中一项重要性质是进展性(即无死锁)。分布式算法通常类似于多参与方通信协议,但证明其性质(尤其是与进展性密切相关的终止性)可能较为复杂。由于分布式算法常为应对故障而设计,因此将容错机制集成到会话类型中,是迈向用会话类型验证分布式算法的第一步。我们扩展了多参与方会话类型以应对系统故障(如不可靠通信和进程崩溃),并通过故障模式增强进程的语义,这些模式可用于表示系统需求(例如故障探测器)。为阐明该方法,我们分析了Chandra与Toueg提出的经典旋转协调器算法的一个变体。