Getting a bucket with Amazon S3 compatible storage on Snowball Edge on a Snowball Edge - AWS Snowball Edge Developer Guide

Getting a bucket with Amazon S3 compatible storage on Snowball Edge on a Snowball Edge

The following example gets an Amazon S3 compatible storage on Snowball Edge bucket using the AWS CLI. To use this command, replace each user input placeholder with your own information.

aws s3control get-bucket --account-id 123456789012 --bucket amzn-s3-demo-bucket --profile your-profile --endpoint-url https://s3ctrlapi-endpoint-ip

For more information about this command, see get-bucket in the AWS CLI Command Reference.

The following Amazon S3 compatible storage on Snowball Edge example gets a bucket using the SDK for Java. For more information, see GetBucket in the Amazon Simple Storage Service API Reference.

import com.amazonaws.services.s3control.model.*; public void getBucket(String bucketName) { GetBucketRequest reqGetBucket = new GetBucketRequest() .withBucket(bucketName) .withAccountId(AccountId); GetBucketResult respGetBucket = s3ControlClient.getBucket(reqGetBucket); System.out.printf("GetBucket Response: %s%n", respGetBucket.toString()); }