Note that there are some explanatory texts on larger screens.

plurals
  1. PO
    primarykey
    data
    text
    <p>Merkle trees limit the amount of data transferred when synchronizing. The general assumptions are:</p> <ol> <li>Network I/O is more expensive than local I/O + computing the hashes.</li> <li>Transferring the entire sorted key space is more expensive than progressively limiting the comparison over several steps.</li> <li>The key spaces have fewer discrepancies than similarities.</li> </ol> <p>A Merkle Tree exchange would look like this:</p> <ol> <li>Start with the root of the tree (a list of one hash value).</li> <li>The origin sends the list of hashes at the current level.</li> <li>The destination diffs the list of hashes against its own and then requests subtrees that are different. If there are no differences, the request can terminate.</li> <li>Repeat steps 2 and 3 until leaf nodes are reached.</li> <li>The origin sends the values of the keys in the resulting set.</li> </ol> <p>In the typical case, the complexity of synchronizing the key spaces will be log(N). Yes, at the extreme, where there are no keys in common, the operation will be equivalent to sending the entire sorted list of hashes, O(N). One could amortize the expense of building Merkle trees by building them dynamically as writes come in and keeping the serialized form on disk.</p> <p>I can't speak to how Dynamo or Cassandra use Merkle trees, but Riak stopped using them for intra-cluster synchronization (hinted handoff and read-repair are sufficient in most cases). We have plans to add them back later after some internal architectural bits have changed.</p> <p>For more information about Riak, we encourage you to join the mailing list: <a href="http://lists.basho.com/mailman/listinfo/riak-users_lists.basho.com">http://lists.basho.com/mailman/listinfo/riak-users_lists.basho.com</a></p>
    singulars
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    plurals
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. VO
      singulars
      1. This table or related slice is empty.
    2. VO
      singulars
      1. This table or related slice is empty.
    3. VO
      singulars
      1. This table or related slice is empty.
 

Querying!

 
Guidance

SQuiL has stopped working due to an internal error.

If you are curious you may find further information in the browser console, which is accessible through the devtools (F12).

Reload