Examples of listObjectsChunked()


Examples of org.jets3t.service.S3Service.listObjectsChunked()

        // List items in chunks of size 2, ensure we get a total of seven.
        int chunkedObjectsCount = 0;
        int chunkedIterationsCount = 0;
        String priorLastKey = null;
        do {
            S3ObjectsChunk chunk = s3Service.listObjectsChunked(
                bucket.getName(), null, null, 2, priorLastKey);
            priorLastKey = chunk.getPriorLastKey();
            chunkedObjectsCount += chunk.getObjects().length;
            chunkedIterationsCount++;
        } while (priorLastKey != null);
View Full Code Here

Examples of org.jets3t.service.S3Service.listObjectsChunked()

            objectsList.size(), chunkedObjectsCount);
        assertEquals("Chunked bucket listing ran for an unexpected number of iterations",
            (objectsList.size() + 1) / 2, chunkedIterationsCount);
       
        // List objects with a prefix and delimiter to check common prefixes.
        S3ObjectsChunk chunk = s3Service.listObjectsChunked(
            bucket.getName(), "dir1/", "/", 100, null);
        assertEquals("Chunked bucket listing with prefix and delimiter retreived incorrect number of objects",
            3, chunk.getObjects().length);
        assertEquals("Chunked bucket listing with prefix and delimiter retreived incorrect number of common prefixes",
            1, chunk.getCommonPrefixes().length);
View Full Code Here

Examples of org.jets3t.service.S3Service.listObjectsChunked()

         * standard object listing with a delimiter string. 
         */
        long startTime = System.currentTimeMillis();
       
        // Find all the objects and common prefixes at the top level.
        S3ObjectsChunk initialChunk = restService.listObjectsChunked(bucketName, null, delimiter, 1000, null, true);
       
        long totalElapsedTime = System.currentTimeMillis() - startTime;
               
        // We will use the common prefix strings, if any, to perform sub-listings
        final String[] commonPrefixes = initialChunk.getCommonPrefixes();
View Full Code Here

Examples of org.jets3t.service.S3Service.listObjectsChunked()

         * standard object listing with a delimiter string.
         */
        long startTime = System.currentTimeMillis();

        // Find all the objects and common prefixes at the top level.
        StorageObjectsChunk initialChunk = restService.listObjectsChunked(
            bucketName, null, delimiter, 1000, null, true);

        long totalElapsedTime = System.currentTimeMillis() - startTime;

        // We will use the common prefix strings, if any, to perform sub-listings
View Full Code Here

Examples of org.jets3t.service.impl.rest.httpclient.RestS3Service.listObjectsChunked()

         * standard object listing with a delimiter string. 
         */
        long startTime = System.currentTimeMillis();
       
        // Find all the objects and common prefixes at the top level.
        S3ObjectsChunk initialChunk = restService.listObjectsChunked(bucketName, null, delimiter, 1000, null, true);
       
        long totalElapsedTime = System.currentTimeMillis() - startTime;
               
        // We will use the common prefix strings, if any, to perform sub-listings
        final String[] commonPrefixes = initialChunk.getCommonPrefixes();
View Full Code Here

Examples of org.jets3t.service.impl.rest.httpclient.RestS3Service.listObjectsChunked()

         * standard object listing with a delimiter string.
         */
        long startTime = System.currentTimeMillis();

        // Find all the objects and common prefixes at the top level.
        StorageObjectsChunk initialChunk = restService.listObjectsChunked(
            bucketName, null, delimiter, 1000, null, true);

        long totalElapsedTime = System.currentTimeMillis() - startTime;

        // We will use the common prefix strings, if any, to perform sub-listings
View Full Code Here

Examples of org.jets3t.service.impl.rest.httpclient.RestStorageService.listObjectsChunked()

            // List items in chunks of size 2, ensure we get a total of seven.
            int chunkedObjectsCount = 0;
            int chunkedIterationsCount = 0;
            String priorLastKey = null;
            do {
                StorageObjectsChunk chunk = service.listObjectsChunked(
                    bucketName, null, null, 2, priorLastKey);
                priorLastKey = chunk.getPriorLastKey();
                chunkedObjectsCount += chunk.getObjects().length;
                chunkedIterationsCount++;
            } while (priorLastKey != null);
View Full Code Here

Examples of org.jets3t.service.impl.rest.httpclient.RestStorageService.listObjectsChunked()

                objectsList.size(), chunkedObjectsCount);
            assertEquals("Chunked bucket listing ran for an unexpected number of iterations",
                (objectsList.size() + 1) / 2, chunkedIterationsCount);

            // List objects with a prefix and delimiter to check common prefixes.
            StorageObjectsChunk chunk = service.listObjectsChunked(
                bucketName, "dir1/", "/", 100, null);
            assertEquals("Chunked bucket listing with prefix and delimiter retreived incorrect number of objects",
                3, chunk.getObjects().length);
            assertEquals("Chunked bucket listing with prefix and delimiter retreived incorrect number of common prefixes",
                1, chunk.getCommonPrefixes().length);
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. 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.