Go to file
zhuo1ang b80ac83420
add check txn status, read key, read SI check (#37)
* Add CheckTxnStatus Msgs

* Add CheckTxnStatus, haven't checked by the TLC

revert a change

DistributedTransaction: fix checkTxnStatus bugs

DistributedTransaction: CheckTxnStatus: refactor

change a var name

Co-authored-by: Andy Lok <andylokandy@hotmail.com>

DistributedTransaction: CheckTxnStatus: format spec

update CheckTxnStatus comment

Co-authored-by: Andy Lok <andylokandy@hotmail.com>

DistributedTransaction: CheckTxnStatus: update comments

* Add SI check

DistributedTransactions: upd min_commit_ts

DistributedTransactions: fix tla parse err

DistributedTransactions: upd tests

upd lock failed

DistributedTransactions: upd read write keys

DistributedTransactions: upd Test2

DistributedTransactions: fix many bugs

* DistributedTransactions: extract unlock_key function

DistributedTransactions: avoid client check txn rollback itself

DistributedTransactions: add ClientCheckTxnStatus to `Next`

DistributedTransactions: amend pessimistic lock

DistributedTransactions: add read SI check

DistributedTransactions: upd pdf version

DistributedTransactions: remove ServerCleanupLock

DistributedTransactions: refactor ClientReadFailed CheckTxnStatus

DistributedTransactions: upd server lock key

DistributedTransactions: fix ClientRetryLockKey bug

DistributedTransactions: fix ReadSI def

* DistributedTransactions: upd max read times

DistributedTransactions: upd max read times

DistributedTransactions: fix bug

DistributedTransactions: upd

DistributedTransactions: refactor, upd some comments

DistributedTransactions: refactor, upd

* DistributedTransaction: Add max client check txn times

DistributedTransaction: upd lock min_commit_ts check

DistributedTransaction: rename wrong name to current_ts

DistributedTransaction: reformat some code

* fix wrong pessimistic lock amend

DistributedTransactions: fix pessimistic lock amend bug

upd

upd

upd

upd

upd

upd

upd

upd

* upd read SI check

upd

refactor ClientRetryLockKey

upd ClientRetryCommit

upd max_lock_key_time

upd

fix bugs

upd pessimistic ReadSI check, same as optimistic one

* upd

remove some resp msgs

upd possible msg lost

* apply code review suggestion

upd

* restucture distributed transaction spec

Signed-off-by: Andy Lok <andylokandy@hotmail.com>

* fix comment

Signed-off-by: Andy Lok <andylokandy@hotmail.com>

* update comment

Signed-off-by: Andy Lok <andylokandy@hotmail.com>

* update assume

Signed-off-by: Andy Lok <andylokandy@hotmail.com>

* update comment

Signed-off-by: Andy Lok <andylokandy@hotmail.com>

* enable snapshot checks

Signed-off-by: Andy Lok <andylokandy@hotmail.com>

* fix pessimistic si check

Signed-off-by: Andy Lok <andylokandy@hotmail.com>

* add comment

Signed-off-by: Andy Lok <andylokandy@hotmail.com>

* add comment

Signed-off-by: Andy Lok <andylokandy@hotmail.com>

* add comment

Signed-off-by: Andy Lok <andylokandy@hotmail.com>

* fix typo

Signed-off-by: Andy Lok <andylokandy@hotmail.com>

* fix dead end in optimistic prewrite

Signed-off-by: Andy Lok <andylokandy@hotmail.com>

* add test5

Signed-off-by: Andy Lok <andylokandy@hotmail.com>

Co-authored-by: Andy Lok <andylokandy@hotmail.com>
2021-08-22 22:06:49 +08:00
CollapseRollbacks move collapserollback optimization to a new separate directory (#24) 2018-08-22 11:33:57 -07:00
ConcurrentPercolator move collapserollback optimization to a new separate directory (#24) 2018-08-22 11:33:57 -07:00
DistributedTransaction add check txn status, read key, read SI check (#37) 2021-08-22 22:06:49 +08:00
OptimizedCommitTS optimized commit ts: remove the cost of getting commitTS (#20) 2018-05-14 17:55:33 +08:00
Percolator percolator: allow clients having different primary keys. (#16) 2018-04-02 14:04:53 +08:00
Raft Port raft from ongardie/raft.tla as-is. (#3) 2018-02-01 15:20:23 +08:00
RaftMerge RaftMerge: rollback and TLC models. (#11) 2018-03-22 14:56:07 +08:00
TwoPC Fix silly error in Coq proof. 2018-01-21 20:45:05 +08:00
.gitignore add check txn status, read key, read SI check (#37) 2021-08-22 22:06:49 +08:00
LICENSE Initial commit 2017-12-19 19:12:25 +08:00
README.md Update README.md 2018-05-08 22:52:09 -07:00

TLA+ in TiDB

About TLA+

TLA+ is a formal specification and verification language to help engineers design, specify, reason about, and verify complex software and hardware systems. It is widely used to verify the algorithms in distributed systems.

Using TLA+ in TiDB

In TiDB, we use TLA+ for the following purposes:

  • To verify the distributed consensus algorithm - Raft.
  • To verify the implementation of distributed transaction.

For further information about TLA+, see tla-plus-resources.