スティルハウスの書庫の書庫

はてなダイアリーで書いてた「スティルハウスの書庫」を移転してきました。

Bigtableと分散KVS


UNIX managinekey-valuekey-value pairKVSRDBRDB使NoSQL

BigtableKVSKVSKVSBigtable

KVS使
ここで言うところの分散KVSには、BigTableやCassandraなどの、いわゆるMulti dimensional sorted storeは含めていない。
これらの分散データストアはkey-valueよりも高級なデータモデルを持ち、単純なKVSの効率上の問題を解決しようとしている。

KVSBigtableDHTKVS

Bigtable: A Distributed Storage System for Structured Data
p1
2 Data Model

A Bigtable is a sparse, distributed, persistent multidimensional sorted map. The map is indexed by a row key, column key, and a timestamp; each value in the map is an uninterpreted array of bytes.

(row:string, column:string, time:int64) → string

Bigtable(row:string, column:string, time:int64)mapmapKVSKVS

KVSmultidimensionalsorted

multidimensional?


2BigtableGoogleWebmultidimensional

Google App EngineBigtablemultidimensional便multidimensionalBigtable

sorted?


sortedBigtablesparse

BigtableKVSBigtableApp EngineGQLJDOQL

Bigtable

p12
In terms of the distributed data storage model that one might provide to application developers, we believe the key-value pair model provided by distributed B-trees or distributed hash tables is too limiting. Key-value pairs are a useful building block, but they should not be the only building block one provides to developers. The model we chose is richer than simple key-value pairs, and supports sparse semi-structured data. Nonetheless, it is still simple enough that it lends itself to a very efficient flat-file representation, and it is transparent enough (via locality groups) to allow our users to tune important behaviors of the system.


  • 分散B-treeやDHTによるkey-value pairモデルのみではアプリ開発者にとって制限が大きすぎる
  • key-value pairは便利な構成要素だが、それだけでは足りない
  • そこでBigtableではsparseな半構造データ(=スキーマレスな構造化データ)を扱える、よりリッチなモデルを提供する
  • かつ、非常に効率的なフラットファイル構造に保存したり、(ローカリティグループにより)システムの重要な振る舞いをユーザーが調整することが可能

Bigtable=分散KVSベースのレンジスキャン可能な表形式データストア


KVSBigtableApp Engine調DHT1

BigtableKVS

NoSQLw

追記


GoogleBigtableBigTable 
SmalltalkSmallTalkJavaJAVAw

11/19追記

「multidimensional」の解釈については、考えが変わりました: http://d.hatena.ne.jp/kazunori_279/20091119/1258593439

12/14追記

Google自身はBigtableのことを分散KVSと捉えているようです:

How Entities and Indexes are Stored

Background

App Engine's datastore is built on top of Bigtable, a large, distributed key-value store that is built to scale.