說說FoundationDB,foundation

來源:互聯網
上載者:User

說說FoundationDB,foundation
FoundationDB

Apple收購了FoundationDB1,而且後者從開源立即變成了閉源。說實話,在此之前都沒有注意到還有這麼一個DBMS產品2。從官網上看,它的一些設計理念還是比較切合實際的,畢竟分布式DBMS存在很多難以解決的問題,要在短期內做到Oracle等傳統RDBMS那樣的程度是不現實的。例如它把重點放到了核心特性上,做了取捨3,4:

  1. 可擴充性,採用Shared-nothing架構。
  2. ACID,支援可序列化的隔離等級。
  3. 容錯,不僅僅是避免單點故障。
  4. 複製,多副本儲存。
  5. 資料模型,有序KV儲存。
  6. 變更通知,用戶端可以訂閱記錄的修改。
  7. 原子操作,避免了Read-modify-write?
  8. OLTP,適合小的讀和寫。OLTP是有限制的,例如不支援修改太大的事務。
  9. OLAP,支援範圍掃描大批資料。OLAP不等於大量資料掃描。
  10. 核心不支援查詢語言,只有API。
  11. 並發控制採用MVCC和開放式並行存取控制。
  12. 執行緒模式,不是一串連一線程。
  13. 應用可以是互動,不依賴預存程序。
  14. 快照形式的備份。不確認這個是否保持一致性。

不過,從這些材料裡並不能準確判斷它實際的做法5以及完整的限制6。Quora裡頭找到一個2013年的問答7,說到了做這個系統的一些取捨,可以一看。還有其他的一些材料:

  1. http://2014.nosql-matters.org/cgn/wp-content/uploads/2014/05/Jennifer-Rullmann-NoSQL-and-ACID.pdf
  2. http://www.methodsandtools.com/archive/acidnosqldatabase.php 
    As Gilbert and Lynch note, their proof relies on an asynchronous model in which "there is no clock, and nodes must make decisions based only on the messages received and local computation." Mahajan revisit Gilbert and Lynch’s work and strengthen its result by employing an asynchronous model allowing local clocks, but no clock globally visible to all nodes. … Real Time Causal (RTC) consistency that is strictly stronger than eventual consistency. Percolator, Megastore, and, most recently, Spanner.

很多人喜歡把NoSQL、NewSQL與傳統的RDBMS相比。在很大程度上,這種比較是不太容易的,因為它們針對的需求以及設計的權衡存在著巨大的區別。例如:

  1. 處理的資料量。傳統的OLTP資料不會太大,集中式系統可以很好的處理。不過,一旦資料分布在不同的IDC,情況就很不一樣了。
  2. 可靠性要求。集中式系統與分布式系統的處理方式和能力顯然不可能一樣。Paxos遠在RDBMS成熟之後才出現。
  3. 資料模型。新的資料庫很少能夠支援好關聯式模式的,例如各種約束,以及衍生出來的索引、序列等特性。
  4. 查詢語言。API還是SQL,甚至XQuery?
  5. 資料一致性。集中式系統的ACID顯然要勝出一籌。
  6. 重要功能。預存程序、視圖、觸發器、資料倉儲,很容易就可以列出一堆新系統很難做到的特性。

One size does not fit all。

Footnotes:1 

https://foundationdb.com/

https://en.wikipedia.org/wiki/FoundationDB

https://foundationdb.com/key-value-store/features

https://foundationdb.com/key-value-store/white-papers/anti-features

https://foundationdb.com/files/Architecture.pdf

https://foundationdb.com/files/FoundationDB-KeyValueStore-Spec-Sheet-3.0.x.pdf

https://www.quora.com/What-is-FoundationDBs-secret-sauce

相關文章

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.