Class ComputeRootHash
- java.lang.Object
-
- org.apache.accumulo.test.replication.merkle.cli.ComputeRootHash
-
public class ComputeRootHash extends Object
Given a table created byGenerateHashes
which contains the leaves of a Merkle tree, compute the root node of the Merkle tree which can be quickly compared to the root node of another Merkle tree to ascertain equality.
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description static class
ComputeRootHash.ComputeRootHashOpts
-
Constructor Summary
Constructors Constructor Description ComputeRootHash()
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description byte[]
getHash(Connector conn, String table, String hashName)
byte[]
getHash(ComputeRootHash.ComputeRootHashOpts opts)
protected ArrayList<MerkleTreeNode>
getLeaves(Connector conn, String tableName)
static void
main(String[] args)
-
-
-
Method Detail
-
getHash
public byte[] getHash(ComputeRootHash.ComputeRootHashOpts opts) throws AccumuloException, AccumuloSecurityException, TableNotFoundException, NoSuchAlgorithmException
-
getHash
public byte[] getHash(Connector conn, String table, String hashName) throws TableNotFoundException, NoSuchAlgorithmException
-
getLeaves
protected ArrayList<MerkleTreeNode> getLeaves(Connector conn, String tableName) throws TableNotFoundException
- Throws:
TableNotFoundException
-
-