7 research outputs found

    Sessions multi-parties réactives

    Get PDF
    Ensuring that communication-centric systems interact according to an intended protocol is an important but difficult problem, particularly for systems with some reactive or timed components. To rise to this challenge, we study the integration of session-based concurrency and Synchronous Reactive Programming (SRP). We propose a process calculus for multiparty sessions enriched with features from SRP. In this calculus, protocol participants may broadcast messages, suspend themselves while waiting for a message, and also react to events. Our main contribution is a session type system for this calculus, which enforces session correctness in terms of communication safety and protocol fidelity, and ensures two time-related properties that we call output persistence and input timeliness. Our type system departs significantly from existing ones, specifically as it captures the notion of logical instant typical of SRP.Assurer que les systèmes centrés sur la communication interagissent en accord avec un protocole donné est un problème important et difficile à résoudre, en particulier lorsque certains composants de ces systèmes sont réactifs ou temporisés. Pour relever ce défi, nous étudions l’intégration de primitives de la programmation réactive synchrone (PRS) dans les calculs de sessions. Nous proposons un calcul de sessions multi-parties enrichi avec des fonctionnalités typiques de la PRS. Dans ce calcul, les participants d’une session peuvent diffuser des messages, se suspendre dans l’attente de messages, et également réagir à des événements. Notre contribution principale est un système de types pour ce calcul, qui garantit deux propriétés classiques des calculs de sessions : l’absence d’erreurs de communication et la conformité au protocole. De plus, ce système de types assure deux propriétés liées au temps, que nous appelons “persistance des outputs” et “gestion sans latence des inputs”. Notre système de types se démarque de façon significative des systèmes de types de session existants, en particulier en ce qu’il rend compte de la notion d’instant logique qui est caractéristique de la PRS

    Session-based concurrency, declaratively

    Get PDF
    Session-based concurrency is a type-based approach to the analysis of message-passing programs. These programs may be specified in an operational or declarative style: the former defines how interactions are properly structured; the latter defines governing conditions for correct interactions. In this paper, we study rigorous relationships between operational and declarative models of session-based concurrency. We develop a correct encoding of session 휋-calculus processes into the linear concurrent constraint calculus (횕회회), a declarative model of concurrency based on partial information (constraints). We exploit session types to ensure that our encoding satisfies precise correctness properties and that it offers a sound basis on which operational and declarative requirements can be jointly specified and reasoned about. We demonstrate the applicability of our results by using our encoding in the specification of realistic communication patterns with time and contextual information

    Sessions multi-parties réactives

    Get PDF
    Ensuring that communication-centric systems interact according to an intended protocol is an important but difficult problem, particularly for systems with some reactive or timed components. To rise to this challenge, we study the integration of session-based concurrency and Synchronous Reactive Programming (SRP). We propose a process calculus for multiparty sessions enriched with features from SRP. In this calculus, protocol participants may broadcast messages, suspend themselves while waiting for a message, and also react to events. Our main contribution is a session type system for this calculus, which enforces session correctness in terms of communication safety and protocol fidelity, and ensures two time-related properties that we call output persistence and input timeliness. Our type system departs significantly from existing ones, specifically as it captures the notion of logical instant typical of SRP.Assurer que les systèmes centrés sur la communication interagissent en accord avec un protocole donné est un problème important et difficile à résoudre, en particulier lorsque certains composants de ces systèmes sont réactifs ou temporisés. Pour relever ce défi, nous étudions l’intégration de primitives de la programmation réactive synchrone (PRS) dans les calculs de sessions. Nous proposons un calcul de sessions multi-parties enrichi avec des fonctionnalités typiques de la PRS. Dans ce calcul, les participants d’une session peuvent diffuser des messages, se suspendre dans l’attente de messages, et également réagir à des événements. Notre contribution principale est un système de types pour ce calcul, qui garantit deux propriétés classiques des calculs de sessions : l’absence d’erreurs de communication et la conformité au protocole. De plus, ce système de types assure deux propriétés liées au temps, que nous appelons “persistance des outputs” et “gestion sans latence des inputs”. Notre système de types se démarque de façon significative des systèmes de types de session existants, en particulier en ce qu’il rend compte de la notion d’instant logique qui est caractéristique de la PRS

    Session-based concurrency, declaratively

    Get PDF
    Session-based concurrency is a type-based approach to the analysis of message-passing programs. These programs may be specified in an operational or declarative style: the former defines how interactions are properly structured; the latter defines governing conditions for correct interaction

    Statically Safe Distributed Programming

    Get PDF
    The Internet and the services it provides have become an omnipresent part of our lives. Asynchronous distributed systems form the basis of these services. Resiliency in the face of partial failures is an essential requirement for many distributed systems, meaning the systems must continue to function as specified even if several components fail. Ensuring correct behavior, particularly when it comes to failures and asynchrony, makes programming such systems very challenging. Multiparty session types (MPSTs) is a typing discipline for concurrent processes that statically ensures desired properties, such as the absence of message reception errors and deadlocks. These properties can help developers implement correct asynchronous message-passing applications. However, existing MPSTs do not support the specification and verification of partial failure-handling or practical fault-tolerant protocols that handle and recover from partial failures. This fundamentally limits the applicability of MPSTs to asynchronous real-world distributed systems. In this thesis we present our article “A Typing Discipline for Statically Verified Crash Failure Handling in Distributed Systems” [VCE+ 18], which is the first MPST formulation for crash failure handling in asynchronous distributed systems. This work features a lightweight coordinator modeled after widely used systems such as Apache ZooKeeper and Chubby. For this formulation we developed a typing discipline based on MPSTs that supports the specification and static verification of multiparty protocols with failure handling. The model preserves the distributed nature of MPSTs and interacts only with the lightweight coordinator for the purpose of critical decision-making around failure handling. The type system provides subject reduction despite the possibility of failures occurring at runtime. We implemented our formulation as a prototype in Scala, using Apache ZooKeeper for coordination, and used it to implement and verify a distributed logistic regression (LR) model. In the accompanying performance evaluation, the session type distributed LR model has a performance comparable to failure agnostics distributed LR models in the absence of failures. We also present our article, “A Multiparty Session Typing Discipline for Fault-tolerant Event-driven Distributed Programming” [VHEZ21], which combines ideas from the previous model with observations from fault-tolerant middleware systems. This work is the first formulation of MPSTs for practical fault-tolerant distributed programming of asynchronous distributed systems. In this work, we give structure to communication patterns involving asynchronous communication and concurrent failures and integrate the features required to express practical fault-tolerant protocols involving dynamic replacement of failed parties and the retrying of failed protocol segments in the presence of imperfect failure detection (perfect failure detection is impossible in asynchronous distributed systems). Key to our approach is the development of the first model of event-driven concurrency for multiparty sessions to unify the session-typed handling of failures and regular I/O events. Moreover, the characteristics of our model allow us to prove a global progress property for well-typed processes engaged in multiple concurrent sessions. Global progress traditionally does not hold in MPST systems. To demonstrate its practicality, we implement our approach as a toolchain for Scala and use it to specify and implement a session-typed version of the cluster manager (CM) of the widely employed Apache Spark data analytics engine. Our session-typed CM integrates with other vanilla Spark components to give a functioning Spark runtime, i.e., it can execute existing unmodified third-party Spark applications. Measured on an industry-standard benchmark Apache Spark has an average performance overhead below 10% when using our session-typed CM instead of Spark’s default CM, in the absence of failures. The developed MPSTs typing disciplines and prototypes enable the specification and verification of practical distributed applications that handle partial failures. Thus, we enable the verification of desired properties and, in turn, help develop correct distributed applications

    Session-Based Concurrency, Reactively

    Get PDF
    International audienceThis paper concerns formal models for the analysis of communication -centric software systems that feature declarative and reactive behaviors. We focus on session-based concurrency, the interaction model induced by session types, which uses (variants of) the π-calculus as specification languages. While well-established, such process models are not expressive enough to specify declarative and reactive behaviors common in emerging communication-centric software systems. Here we propose the synchronous reactive programming paradigm as a uniform foundation for session-based concurrency. We present correct encodings of session-based calculi into ReactiveML, a synchronous reactive programming language. Our encodings bridge the gap between process specifications and concurrent programs in which session-based concurrency seamlessly coexists with declarative, reactive, timed, and contextual behaviors
    corecore