Database
NoSQL (Not only SQL)
-
Key-value
-
Document
-
Graph
-
...
ACID
Transaction, 一連串必須要一起進行的操作,如果一個操錯失敗,所以已經執行的操作都必須取消
-
Atomicity
-
Consistency
-
Isolation
-
Durability
Just a 原子操作
CAP theorem
CAP定理101—分散式系統,有一好沒兩好. Cap Theorem 101 | by YH Yu | 後端新手村 | Medium
-
Consistency: all client see all same data at same time
-
Availability
-
Partition tolerance: network connection
Eventually Consistency 最終一致性
保證最終會同步
Strong Consistency 強一致性
N replica
W is number of write / udpate replica
R is number of read from replica
if W + R > N, Strong Consistency
it means atleast one of the W and R are overlap