Package org.apache.cassandra.utils

Examples of org.apache.cassandra.utils.MerkleTree$StopRecursion$InvalidHash


        Validator validator = new Validator(new CFPair(tablename, cfname));
        validator.prepare(store);
        validator.complete();

        // grab reference to the tree
        MerkleTree tree = validator.tree;

        // notify ourself (should immediately be delivered into AE_STAGE)
        aes.notifyNeighbors(validator, LOCAL, Arrays.asList(LOCAL));
        flushAES().get(5, TimeUnit.SECONDS);
       
View Full Code Here


    {
        // generate a tree
        Validator validator = new Validator(new CFPair(tablename, cfname));
        validator.prepare(store);
        validator.complete();
        MerkleTree ltree = validator.tree;

        // and a clone
        validator = new Validator(new CFPair(tablename, cfname));
        validator.prepare(store);
        validator.complete();
        MerkleTree rtree = validator.tree;

        // change a range we own in one of the trees
        Token ltoken = StorageService.instance.getLocalToken();
        ltree.invalidate(ltoken);
        MerkleTree.TreeRange changed = ltree.invalids(StorageService.instance.getLocalPrimaryRange()).next();
View Full Code Here

       
        // generate a tree
        Validator validator = new Validator(request);
        validator.prepare(store);
        validator.complete();
        MerkleTree ltree = validator.tree;

        // and a clone
        validator = new Validator(request);
        validator.prepare(store);
        validator.complete();
        MerkleTree rtree = validator.tree;

        // change a range in one of the trees
        Token ltoken = StorageService.getPartitioner().midpoint(local_range.left, local_range.right);
        ltree.invalidate(ltoken);
        MerkleTree.TreeRange changed = ltree.get(ltoken);
View Full Code Here

    {
        // generate a tree
        Validator validator = new Validator(request);
        validator.prepare(store);
        validator.complete();
        MerkleTree ltree = validator.tree;

        // and a clone
        validator = new Validator(request);
        validator.prepare(store);
        validator.complete();
        MerkleTree rtree = validator.tree;

        // change a range we own in one of the trees
        Token ltoken = StorageService.instance.getLocalToken();
        ltree.invalidate(ltoken);
        MerkleTree.TreeRange changed = ltree.invalids(StorageService.instance.getLocalPrimaryRange()).next();
View Full Code Here

        Validator validator = new Validator(new CFPair(tablename, cfname));
        validator.prepare();
        validator.complete();

        // grab reference to the tree
        MerkleTree tree = validator.tree;

        // notify ourself (should immediately be delivered into AE_STAGE)
        aes.notifyNeighbors(validator, LOCAL, Arrays.asList(LOCAL));
        flushAES().get(5, TimeUnit.SECONDS);
       
View Full Code Here

        Validator validator = new Validator(new CFPair("Keyspace1", "lcf"));
        validator.prepare();

        // create a clone with no values filled
        validator.complete();
        MerkleTree ltree = validator.tree;
        validator = new Validator(new CFPair("Keyspace1", "rcf"));
        validator.prepare();
        validator.complete();
        MerkleTree rtree = validator.tree;

        // change a range in one of the trees
        Token min = StorageService.instance.getPartitioner().getMinimumToken();
        ltree.invalidate(min);
        MerkleTree.TreeRange changed = ltree.invalids(new Range(min, min)).next();
View Full Code Here

        // with two SSTables
        ColumnFamilyStoreUtils.writeColumnFamily(rms);
        ColumnFamilyStore store = ColumnFamilyStoreUtils.writeColumnFamily(rms);
       
        // force a major compaction, and wait for it to finish
        MerkleTree old = aes.getCachedTree(tablename, cfname, LOCAL);
        CompactionManager.instance().submitMajor(store, 0).get(5000, TimeUnit.MILLISECONDS);

        // check that a tree was created and cached
        flushAES().get(5000, TimeUnit.MILLISECONDS);
        assert old != aes.getCachedTree(tablename, cfname, LOCAL);
View Full Code Here

        Validator validator = new Validator(new CFTuple(tablename, cfname), LOCAL);
        validator.prepare();
        validator.complete();

        // grab reference to the tree
        MerkleTree tree = validator.tree;

        // notify ourself (should immediately be delivered into AE_STAGE)
        aes.notifyNeighbors(validator, LOCAL, Arrays.asList(LOCAL));
        flushAES().get(5, TimeUnit.SECONDS);
       
View Full Code Here

        validator.prepare();

        // create a clone with no values filled

        validator.complete();
        MerkleTree ltree = validator.tree;
        validator = new Validator(new CFTuple("rtable", "rcf"), LOCAL);
        validator.prepare();
        validator.complete();
        MerkleTree rtree = validator.tree;

        // change a range in one of the trees
        Token min = StorageService.instance().getPartitioner().getMinimumToken();
        ltree.invalidate(min);
        MerkleTree.TreeRange changed = ltree.invalids(new Range(min, min)).next();
View Full Code Here

    @Before
    public void clear()
    {
        TOKEN_SCALE = new BigInteger("8");
        partitioner = new RandomPartitioner();
        mt = new MerkleTree(partitioner, RECOMMENDED_DEPTH, Integer.MAX_VALUE);
    }
View Full Code Here

TOP

Related Classes of org.apache.cassandra.utils.MerkleTree$StopRecursion$InvalidHash

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.