Model-View-Update-Communicate: Session Types meet the Elm Architecture

10/24/2019
by   Simon Fowler, et al.
0

The Elm programming language pioneers the Model-View-Update (MVU) architecture for writing web applications in a functional style. Although popular amongst developers, MVU has not been studied formally; it is therefore difficult to reason about any extensions, and each implementer must re-discover the essence of the architecture. In this paper we introduce λ_MVU, a formal model of the MVU architecture as a concurrent λ-calculus, and prove its correctness. We extend λ_MVU with subscriptions and commands as found in Elm. By further extending the calculus with linearity and model transitions, we provide the first formal integration of session-typed communication with a GUI framework. We implement our approach in the Links web programming language, and show examples including a two-factor authentication workflow and multi-room chat server.

READ FULL TEXT

page 1

page 2

page 3

page 4

research
04/02/2019

FreeST: Context-free Session Types in a Functional Language

FreeST is an experimental concurrent programming language. Based on a co...
research
01/28/2020

Language-Based Web Session Integrity

Session management is a fundamental component of web applications: despi...
research
04/03/2020

Fluent Session Programming in C#

We propose SessionC#, a lightweight session typed library for safe concu...
research
10/13/2020

Nested Session Types

Session types statically describe communication protocols between concur...
research
05/13/2021

On the Monitorability of Session Types, in Theory and Practice (Extended Version)

In concurrent and distributed systems, software components are expected ...
research
03/19/2019

No more, no less - A formal model for serverless computing

Serverless computing, also known as Functions-as-a-Service, is a recent ...
research
03/18/2018

A View-based Programmable Architecture for Controlling and Integrating Decentralized Data

The view and the view update are known mechanism for controlling access ...

Please sign up or login with your details

Forgot password? Click here to reset