Skip to content

Commit 030f5d0

Browse files
authored
Update README (#39)
Reordered models and added a few more links and context to some of the model descriptions.
1 parent 95f5ef1 commit 030f5d0

File tree

1 file changed

+21
-22
lines changed

1 file changed

+21
-22
lines changed

README.md

Lines changed: 21 additions & 22 deletions
Original file line numberDiff line numberDiff line change
@@ -1,30 +1,22 @@
11
# Formal models of core Elasticsearch algorithms
22

3-
This repository contains formal models of core [Elasticsearch](https://github.com/elastic/elasticsearch) algorithms and is directly related to ongoing implementation efforts around [data replication](https://github.com/elastic/elasticsearch/issues/10708) and cluster consensus. We consider this work-in-progress: Models as well as implementations are still evolving and might differ in substantial ways. The formal models mainly serve to illustrate some of the high-level concepts and help to validate resiliency-related aspects.
3+
This repository contains formal models of core [Elasticsearch](https://github.com/elastic/elasticsearch) algorithms and is directly related to implementation efforts around [data replication](https://github.com/elastic/elasticsearch/issues/10708) and [cluster coordination](https://github.com/elastic/elasticsearch/issues/32006). The models in this repository might represent past, current and future designs of Elasticsearch and can differ to their implementations in substantial ways. The formal models mainly serve to illustrate some of the high-level concepts and help to validate resiliency-related aspects.
44

55
## Models
66

7-
### Data replication
7+
### Cluster coordination model
88

9-
The data replication model consists of two files:
9+
The cluster coordination TLA+ model ensures the consistency of cluster state updates and represents the core [cluster coordination](https://github.com/elastic/elasticsearch/issues/32006) and metadata replication algorithm implemented in Elasticsearch 7.0. It consists of two files:
1010

11-
- [TLA+ specification](data/tla/replication.tla)
12-
- [TLC model checking configuration](data/tla/replication.toolbox/replication___model.launch)
13-
14-
### Cluster consensus
15-
16-
The cluster consensus TLA+ model consists of two files:
11+
- [TLA+ specification](ZenWithTerms/tla/ZenWithTerms.tla) which has a [direct one-to-one implementation in Elasticsearch](https://github.com/elastic/elasticsearch/blob/master/server/src/main/java/org/elasticsearch/cluster/coordination/CoordinationState.java)
12+
- [TLC model checking configuration](ZenWithTerms/tla/ZenWithTerms.toolbox/ZenWithTerms___model.launch)
1713

18-
- [TLA+ specification](cluster/tla/consensus.tla)
19-
- [TLC model checking configuration](cluster/tla/consensus.toolbox/consensus___model.launch)
14+
### Data replication model
2015

21-
The cluster consensus Isabelle model consists of the following theories:
16+
The data replication TLA+ model describes the Elasticsearch [sequence number](https://github.com/elastic/elasticsearch/issues/10708) based data replication approach, implemented since Elasticsearch 6.0, which consists of two files:
2217

23-
- [Basic definitions](cluster/isabelle/Preliminaries.thy)
24-
- [An implementation in functional style](cluster/isabelle/Implementation.thy)
25-
- [An implementation in monadic style, along with a proof it's equivalent to the previous](cluster/isabelle/Monadic.thy)
26-
- [The proof that each slot is consistent, based on Lamport's Synod algorithm](cluster/isabelle/OneSlot.thy)
27-
- [The proof that the implementation ensures consistency](cluster/isabelle/Zen.thy)
18+
- [TLA+ specification](data/tla/replication.tla)
19+
- [TLC model checking configuration](data/tla/replication.toolbox/replication___model.launch)
2820

2921
### Replica engine
3022

@@ -35,13 +27,20 @@ handles replication requests.
3527
- [TLA+ specification](ReplicaEngine/tla/ReplicaEngine.tla)
3628
- [TLC model checking configuration](ReplicaEngine/tla/ReplicaEngine.toolbox/ReplicaEngine___model.launch)
3729

38-
### Zen with terms
30+
### Alternative cluster coordination model
3931

40-
An alternative idea for improving the consistency of cluster state updates,
41-
effectively by adding the notion of a _term_ to the existing Zen algorithm.
32+
The alternative cluster coordination TLA+ model consists of two files:
4233

43-
- [TLA+ specification](ZenWithTerms/tla/ZenWithTerms.tla)
44-
- [TLC model checking configuration](ZenWithTerms/tla/ZenWithTerms.toolbox/ZenWithTerms___model.launch)
34+
- [TLA+ specification](cluster/tla/consensus.tla)
35+
- [TLC model checking configuration](cluster/tla/consensus.toolbox/consensus___model.launch)
36+
37+
The alternative cluster consensus Isabelle model consists of the following theories:
38+
39+
- [Basic definitions](cluster/isabelle/Preliminaries.thy)
40+
- [An implementation in functional style](cluster/isabelle/Implementation.thy)
41+
- [An implementation in monadic style, along with a proof it's equivalent to the previous](cluster/isabelle/Monadic.thy)
42+
- [The proof that each slot is consistent, based on Lamport's Synod algorithm](cluster/isabelle/OneSlot.thy)
43+
- [The proof that the implementation ensures consistency](cluster/isabelle/Zen.thy)
4544

4645
## How to edit/run TLA+:
4746

0 commit comments

Comments
 (0)