Package com.basho.riak.client.core.query

Examples of com.basho.riak.client.core.query.Location


                        .build();
       
        node.start();
       
        Namespace ns = new Namespace(Namespace.DEFAULT_BUCKET_TYPE, "test_bucket");
        Location location = new Location(ns, "test_key2");
       
        for (int i = 0; i < 6; i++)
        {
            FetchOperation operation =
                new FetchOperation.Builder(location)
View Full Code Here


                        .build();
       
        node.start();
       
        Namespace ns = new Namespace(Namespace.DEFAULT_BUCKET_TYPE, "test_bucket");
        Location location = new Location(ns, "test_key2");
       
        FetchOperation operation =
            new FetchOperation.Builder(location)
                    .build();
       
View Full Code Here

                        .withRemotePort(startingPort + NetworkTestFixture.ACCEPT_THEN_CLOSE)
                        .build();
        node.start();
       
        Namespace ns = new Namespace(Namespace.DEFAULT_BUCKET_TYPE, "test_bucket");
        Location location = new Location(ns, "test_key2");

        FetchOperation operation =
            new FetchOperation.Builder(location)
                    .build();
       
View Full Code Here

        LongIntIndex longIndex = indexes.getIndex(LongIntIndex.named("dave"));
        longIndex.add(42L);

        ro.setValue(BinaryValue.unsafeCreate(expectedValue));

        Location location = new Location(ns, key);
        StoreOperation operation =
            new StoreOperation.Builder(location)
                .withContent(ro)
                .build();
View Full Code Here

{

    private RiakCounter fetchCounter(BinaryValue type, BinaryValue bucket, BinaryValue key)
        throws ExecutionException, InterruptedException
    {
        Location location = new Location(new Namespace(type, bucket), key);
        DtFetchOperation fetch = new DtFetchOperation.Builder(location).build();
        cluster.execute(fetch);
        DtFetchOperation.Response response = fetch.get();
        RiakDatatype element = response.getCrdtElement();
View Full Code Here

    }

    private RiakSet fetchSet(BinaryValue type, BinaryValue bucket, BinaryValue key)
        throws ExecutionException, InterruptedException
    {
        Location location = new Location(new Namespace(type, bucket), key);
        DtFetchOperation fetch = new DtFetchOperation.Builder(location).build();

        cluster.execute(fetch);
        DtFetchOperation.Response response = fetch.get();
        RiakDatatype element = response.getCrdtElement();
View Full Code Here

    }

    private RiakMap fetchMap(BinaryValue type, BinaryValue bucket, BinaryValue key)
        throws ExecutionException, InterruptedException
    {
        Location location = new Location(new Namespace(type, bucket), key);
        DtFetchOperation fetch = new DtFetchOperation.Builder(location).build();

        cluster.execute(fetch);
        DtFetchOperation.Response response = fetch.get();
        RiakDatatype element = response.getCrdtElement();
View Full Code Here

        resetAndEmptyBucket(new Namespace(counterBucketType, bucketName));

        RiakCounter counter = fetchCounter(counterBucketType, bucketName, key);
        assertEquals((Long) 0L, counter.view());

        Location location = new Location(new Namespace(counterBucketType, bucketName), key);
        for (int i = 0; i < iterations; ++i)
        {
            DtUpdateOperation update =
                new DtUpdateOperation.Builder(location)
                    .withOp(new CounterOp(1))
View Full Code Here

        RiakSet set = fetchSet(setBucketType, bucketName, key);
        assertTrue(set.view().isEmpty());

        Set<BinaryValue> testValues = new HashSet<BinaryValue>(iterations);
        Location location = new Location(new Namespace(setBucketType, bucketName), key);
        BinaryValue ctx = null;
        for (int i = 0; i < iterations; ++i)
        {
            ByteBuffer buff = (ByteBuffer) ByteBuffer.allocate(8).putInt(i).rewind();
            BinaryValue wrapped = BinaryValue.create(buff.array());
View Full Code Here

        RiakSet set = fetchSet(setBucketType, bucketName, key);
        assertTrue(set.view().isEmpty());

        Set<BinaryValue> testValues = new HashSet<BinaryValue>(iterations);
        Location location = new Location(new Namespace(setBucketType, bucketName), key);
        for (int i = 0; i < iterations; ++i)
        {
            ByteBuffer buff = (ByteBuffer) ByteBuffer.allocate(8).putInt(i).rewind();
            BinaryValue wrapped = BinaryValue.create(buff.array());
            testValues.add(wrapped);
View Full Code Here

TOP

Related Classes of com.basho.riak.client.core.query.Location

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.