Dear Wiki user, You have subscribed to a wiki page or wiki category on "Cassandra Wiki" for change notification.
The "ArchitectureOverview" page has been changed by tuxracer69. http://wiki.apache.org/cassandra/ArchitectureOverview?action=diff&rev1=2&rev2=3 -------------------------------------------------- At write time, * you first write to a '''disk commit log''' (sequential) * After write to log it is sent to the appropriate nodes - * Each node receiving write first records it in a local log, then makes update to appropriate '''memtables''' (one for each column family). A Memtable is Cassandra's in-memory representation of key/value pairs + * Each node receiving write first records it in a local log, then makes update to appropriate '''memtables''' (one for each column family). A Memtable is Cassandra's in-memory representation of key/value pairs before the data gets flushed to disk as an SSTable. - before the data gets flushed to disk as an SSTable. * '''Memtables''' are flushed to disk when: * Out of space * Too many keys (128 is default) @@ -144, +143 @@ * Discard tombstones + === Write properties === + + * No reads + * No seeks + * ''Fast'' + * Atomic within ColumnFamily + * Always writable + @@ -158, +165 @@ - Cassandra write properties - No reads No seeks Fast Atomic within ColumnFamily Always writable + == Read == - - - - - == Read path == + === Read path === + * Any node + * Partitioner + * Wait for R responses - Any node Partitioner Wait for R responses Wait for N R responses in the background and perform read repair + * Wait for N - R responses in the background and perform read repair - - - - - - - Cassandra read properties + === Cassandra read properties === + * Read multiple SSTables + * Slower than writes (but still fast) + * Seeks can be mitigated with more RAM + * Scales to billions of rows - Read multiple SSTables Slower than writes (but still fast) Seeks can be mitigated with more RAM Scales to billions of rows - - - - - - - Consistency in a BASE world + === Consistency in a BASE world === + Specify W, number of nodes to wait for - If W + R > N, you will have consistency W=1, R=N W=N, R=1 W=Q, R=Q where Q = N / 2 + 1 + * If W + R > N, you will have consistency + * W=1, R=N + * W=N, R=1 + * W=Q, R=Q where Q = N / 2 + 1 @@ -204, +204 @@ - vs MySQL with 50GB of data + Cassandra vs MySQL with 50GB of data - MySQL + || MySQL || Cassandra || + ||~300ms write || ~0.12ms write|| + ||~350ms read || ~15ms read || - - ~300ms write ~350ms read ~0.12ms write ~15ms read -
