Skip to content

Commit a7acaa5

Browse files
committed
fixed name
1 parent ae7dc11 commit a7acaa5

32 files changed

Lines changed: 35 additions & 35 deletions

javav2/example_code/s3/src/main/java/com/example/s3/GeneratePresignedGetUrlAndRetrieve.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -48,7 +48,7 @@ public class GeneratePresignedGetUrlAndRetrieve {
4848
private final static S3Client s3Client = S3Client.create();
4949

5050
public static void main(String[] args) {
51-
String bucketName = "sdk-example-bucket" + UUID.randomUUID(); // Change bucket name.
51+
String bucketName = "amzn-s3-demo-bucket"; // Replace with your bucket name.
5252
String keyName = "key" + UUID.randomUUID();
5353
String resourcePath = "multipartUploadFiles/s3-userguide.pdf";
5454

javav2/example_code/s3/src/main/java/com/example/s3/GeneratePresignedUrlAndPutFileWithMetadata.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -52,7 +52,7 @@ public class GeneratePresignedUrlAndPutFileWithMetadata {
5252
private final static S3Client s3Client = S3Client.create();
5353

5454
public static void main(String[] args) {
55-
String bucketName = "sdk-example-bucket" + UUID.randomUUID(); // Change bucket name.
55+
String bucketName = "amzn-s3-demo-bucket"; // Replace with your bucket name.
5656
String keyName = "key" + UUID.randomUUID();
5757
String resourcePath = "multipartUploadFiles/s3-userguide.pdf";
5858
// Uncomment the following two lines and comment out the previous two lines to use an image file instead of a PDF file.

javav2/example_code/s3/src/main/java/com/example/s3/GeneratePresignedUrlAndPutFileWithQueryParams.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -43,7 +43,7 @@ public class GeneratePresignedUrlAndPutFileWithQueryParams {
4343
private final static S3Client s3Client = S3Client.create();
4444

4545
public static void main(String[] args) {
46-
String bucketName = "sdk-example-bucket" + UUID.randomUUID(); // Change bucket name.
46+
String bucketName = "amzn-s3-demo-bucket"; // Replace with your bucket name.
4747
String keyName = "key" + UUID.randomUUID();
4848
String resourcePath = "uploadDirectory/file1.txt";
4949
// Uncomment the following two lines and comment out the previous two lines to use an image file instead of a PDF file.

javav2/example_code/s3/src/main/java/com/example/s3/GeneratePresignedUrlAndUploadObject.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -39,7 +39,7 @@ public class GeneratePresignedUrlAndUploadObject {
3939
private static final Logger logger = org.slf4j.LoggerFactory.getLogger(GeneratePresignedUrlAndUploadObject.class);
4040

4141
public static void main(String[] args) {
42-
String bucketName = "sdk-example-bucket" + UUID.randomUUID(); // Change bucket name.
42+
String bucketName = "amzn-s3-demo-bucket"; // Replace with your bucket name.
4343
String keyName = "key" + UUID.randomUUID();
4444

4545
try (S3Client s3Client = S3Client.create()) {

javav2/example_code/s3/src/main/java/com/example/s3/directorybucket/AbortDirectoryBucketMultipartUploads.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -82,7 +82,7 @@ public static void main(String[] args) {
8282
Region region = Region.US_WEST_2;
8383
S3Client s3Client = createS3Client(region);
8484
String zone = "usw2-az1";
85-
String bucketName = "test-bucket-" + System.currentTimeMillis() + "--" + zone + "--x-s3";
85+
String bucketName = "amzn-s3-demo-bucket-" + System.currentTimeMillis() + "--" + zone + "--x-s3";
8686
String objectKey = "largeObject"; // your-object-key
8787
String uploadId;
8888

javav2/example_code/s3/src/main/java/com/example/s3/directorybucket/CompleteDirectoryBucketMultipartUpload.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -99,7 +99,7 @@ public static void main(String[] args) {
9999
Region region = Region.US_WEST_2;
100100
S3Client s3Client = createS3Client(region);
101101
String zone = "usw2-az1";
102-
String bucketName = "test-bucket-" + System.currentTimeMillis() + "--" + zone + "--x-s3";
102+
String bucketName = "amzn-s3-demo-bucket-" + System.currentTimeMillis() + "--" + zone + "--x-s3";
103103
String uploadId;
104104
String objectKey = "largeObject";
105105
Path filePath = getFilePath("directoryBucket/sample-large-object.jpg");

javav2/example_code/s3/src/main/java/com/example/s3/directorybucket/CopyDirectoryBucketObject.java

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -92,8 +92,8 @@ public static void main(String[] args) {
9292
Region region = Region.US_WEST_2;
9393
S3Client s3Client = createS3Client(region);
9494
String zone = "usw2-az1";
95-
String sourceDirectoryBucket = "test-source-bucket-" + System.currentTimeMillis() + "--" + zone + "--x-s3";
96-
String targetDirectoryBucket = "test-destination-bucket-" + System.currentTimeMillis() + "--" + zone + "--x-s3";
95+
String sourceDirectoryBucket = "amzn-s3-demo-source-bucket-" + System.currentTimeMillis() + "--" + zone + "--x-s3";
96+
String targetDirectoryBucket = "amzn-s3-demo-destination-bucket-" + System.currentTimeMillis() + "--" + zone + "--x-s3";
9797
String objectKey = "example-object"; // your-object-key
9898
Path filePath = getFilePath("directoryBucket/sample1.txt");
9999

javav2/example_code/s3/src/main/java/com/example/s3/directorybucket/CreateDirectoryBucket.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -88,7 +88,7 @@ public static void createDirectoryBucket(S3Client s3Client, String bucketName, S
8888
// snippet-end:[s3directorybuckets.java2.directory_bucket_create_bucket.main]
8989

9090
public static void main(String[] args) {
91-
String bucketName = "test-bucket-" + System.currentTimeMillis() + "--usw2-az1--x-s3";
91+
String bucketName = "amzn-s3-demo-bucket-" + System.currentTimeMillis() + "--usw2-az1--x-s3";
9292
Region region = Region.US_WEST_2;
9393
String zone = "usw2-az1";
9494
S3Client s3Client = createS3Client(region);

javav2/example_code/s3/src/main/java/com/example/s3/directorybucket/CreateDirectoryBucketMultipartUpload.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -86,7 +86,7 @@ public static void main(String[] args) {
8686
Region region = Region.US_WEST_2;
8787
S3Client s3Client = createS3Client(region);
8888
String zone = "usw2-az1";
89-
String bucketName = "test-bucket-" + System.currentTimeMillis() + "--" + zone + "--x-s3";
89+
String bucketName = "amzn-s3-demo-bucket-" + System.currentTimeMillis() + "--" + zone + "--x-s3";
9090
String objectKey = "largeObject"; // your-object-key
9191

9292
try {

javav2/example_code/s3/src/main/java/com/example/s3/directorybucket/DeleteDirectoryBucket.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -77,7 +77,7 @@ public static void main(String[] args) {
7777
Region region = Region.US_WEST_2;
7878
S3Client s3Client = createS3Client(region);
7979
String zone = "usw2-az1";
80-
String bucketName = "test-bucket-" + System.currentTimeMillis() + "--" + zone + "--x-s3";
80+
String bucketName = "amzn-s3-demo-bucket-" + System.currentTimeMillis() + "--" + zone + "--x-s3";
8181

8282
try {
8383
// Create the directory bucket

0 commit comments

Comments
 (0)