Abstract:Client-server sessions are based on a variation of the traditional interpretation of linear logic propositions as session types in which non-linear channels (those regulating the interaction between a pool of clients and a single server) are typed by coexponentials instead of the usual exponentials. Coexponentials enable the modeling of racing interactions, whereby clients compete to interact with a single server whose internal state (and thus the offered service) may change as the server processes requests sequentially. In this work we present a fair termination result for CSLL$^\infty$, a core calculus of client-server sessions. We design a type system such that every well-typed term corresponds to a valid derivation in $\mu$MALL$^\infty$, the infinitary proof theory of linear logic with least and greatest fixed points. We then establish a correspondence between reductions in the calculus and principal reductions in $\mu$MALL$^\infty$. Fair termination in CSLL$^\infty$ follows from cut elimination in $\mu$MALL$^\infty$.
What problem does this paper attempt to address?
The problem that this paper attempts to solve is about the fair termination of client - server sessions. Specifically, the author hopes to prove that in CSLL∞ (a core calculus based on a variation of linear logic), all well - typed processes can terminate fairly. Here, fair termination means that every fair and maximal reduction sequence is finite, thus ensuring that under certain fairness assumptions, there will be no infinite reduction sequences.
### Background and Motivation
The exponential modality in traditional linear logic is used to describe that the server can handle an infinite number of requests, but this model is not realistic because it assumes that the server can process multiple requests in parallel, while in fact the server usually processes these requests sequentially. Moreover, each connection may change the internal state of the server, which in turn affects other connections. Therefore, it is inaccurate to use the traditional exponential modality to model client - server interactions.
To solve these problems, Qian et al. proposed CSLL (Client - Server Linear Logic) and introduced coexponential modalities, denoted as ¿T and ¡T, to describe the server's behavior more precisely. However, they failed to provide a complete termination proof and speculated that it would be a complex problem.
### Research Objectives
The main objective of this paper is to prove that well - typed processes in CSLL∞ can terminate fairly by encoding the coexponential modalities in CSLL∞ into fixed points in µMALL∞ (infinitely - valued multiplicative - additive linear logic with least and greatest fixed points) and using the cut - elimination property of µMALL∞.
### Main Contributions
1. **Proposing CSLL∞**: This is an improved variant of CSLL with more traditional reduction semantics.
2. **Establishing a type system**: A type system is designed so that each well - typed term corresponds to a valid derivation in µMALL∞.
3. **Proving fair termination**: Using the cut - elimination property of µMALL∞, it is proved that well - typed processes in CSLL∞ can terminate fairly.
4. **Ensuring livelock freedom**: Combined with deadlock - freedom, fair termination is sufficient to ensure livelock freedom.
### Significance of Fair Termination
The concept of fair termination is weaker than ordinary termination because it does not exclude the possibility of the existence of infinite reduction sequences. However, it guarantees that every fair and maximal reduction sequence is finite. This property is very important in practical applications because it ensures that even if there may be infinite behavior in some cases, under reasonable fairness assumptions, the system can still complete the task within a finite number of steps.
In conclusion, this paper solves the key problem of fair termination in client - server sessions by introducing new logical tools and methods, providing a theoretical basis for further research and application.