Skip to content

Commit c284ae1

Browse files
committed
Updated code according to reviewer's comments.
1 parent 2984696 commit c284ae1

File tree

6 files changed

+31
-32
lines changed

6 files changed

+31
-32
lines changed

dotnetv3/S3/AbortMPUExample/AbortMPUExample/AbortMPU.cs

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -20,22 +20,22 @@ public static async Task Main()
2020
{
2121
string bucketName = "doc-example-bucket";
2222

23-
// If the AWS region defined for your default user is different
24-
// from the AWS regsion where your Amazon S3 bucket is located,
25-
// pass the AWS Region name to the S3 client object's constructor.
26-
// For example, RegionEndpoint.USWest2.
23+
// If the AWS Region defined for your default user is different
24+
// from the Regsion where your Amazon S3 bucket is located,
25+
// pass the Region name to the S3 client object's constructor.
26+
// For example: RegionEndpoint.USWest2.
2727
IAmazonS3 client = new AmazonS3Client();
2828

2929
await AbortMPUAsync(client, bucketName);
3030
}
3131

3232
/// <summary>
33-
/// Makes the call to abort the multi-part copy process.
33+
/// Aborts the multi-part copy process.
3434
/// </summary>
3535
/// <param name="client">The initialized client object used to create
3636
/// the TransferUtility object.</param>
3737
/// <param name="bucketName">The name of the multi-part copy operation
38-
/// is in progress.</param>
38+
/// that is in progress.</param>
3939
public static async Task AbortMPUAsync(IAmazonS3 client, string bucketName)
4040
{
4141
try

dotnetv3/S3/SSECLowLevelMPUcopyObjectExample/SSECLowLevelMPUcopyObjectExample/SSECLowLevelMPUcopyObject.cs

Lines changed: 4 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -25,10 +25,10 @@ public static async Task Main()
2525
string targetKeyName = "sample_file_copy.txt";
2626
string filePath = $"sample\\{targetKeyName}";
2727

28-
// If the AWS region defined for your default user is different
29-
// from the AWS regsion where your Amazon S3 bucket is located,
30-
// pass the AWS Region name to the S3 client object's constructor.
31-
// For example, RegionEndpoint.USWest2.
28+
// If the AWS Region defined for your default user is different
29+
// from the Regsion where your Amazon S3 bucket is located,
30+
// pass the Region name to the S3 client object's constructor.
31+
// For example: RegionEndpoint.USWest2.
3232
IAmazonS3 client = new AmazonS3Client();
3333

3434
// Create the encryption key.
@@ -70,7 +70,6 @@ public static async Task CreateSampleObjUsingClientEncryptionKeyAsync(
7070
string filePath,
7171
string base64Key)
7272
{
73-
// List to store upload part responses.
7473
List<UploadPartResponse> uploadResponses = new List<UploadPartResponse>();
7574

7675
InitiateMultipartUploadRequest initiateRequest = new InitiateMultipartUploadRequest

dotnetv3/S3/SSEClientEncryptionExample/SSEClientEncryptionExample/SSEClientEncryption.cs

Lines changed: 8 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -23,10 +23,10 @@ public static async Task Main()
2323
string keyName = "exampleobject.txt";
2424
string copyTargetKeyName = "examplecopy.txt";
2525

26-
// If the AWS region defined for your default user is different
27-
// from the AWS regsion where your Amazon S3 bucket is located,
28-
// pass the AWS Region name to the S3 client object's constructor.
29-
// For example, RegionEndpoint.USWest2.
26+
// If the AWS Region defined for your default user is different
27+
// from the Regsion where your Amazon S3 bucket is located,
28+
// pass the Region name to the S3 client object's constructor.
29+
// For example: RegionEndpoint.USWest2.
3030
IAmazonS3 client = new AmazonS3Client();
3131

3232
try
@@ -40,14 +40,14 @@ public static async Task Main()
4040
// Upload the object.
4141
PutObjectRequest putObjectRequest = await UploadObjectAsync(client, bucketName, keyName, base64Key);
4242

43-
// Download the object and verify that its contents matche what you uploaded.
43+
// Download the object and verify that its contents match what you uploaded.
4444
await DownloadObjectAsync(client, bucketName, keyName, base64Key, putObjectRequest);
4545

4646
// Get object metadata and verify that the object uses AES-256 encryption.
4747
await GetObjectMetadataAsync(client, bucketName, keyName, base64Key);
4848

4949
// Copy both the source and target objects using server-side encryption with
50-
// a customer-provided encryption key.
50+
// an encryption key.
5151
await CopyObjectAsync(client, bucketName, keyName, copyTargetKeyName, aesEncryption, base64Key);
5252
}
5353
catch (AmazonS3Exception ex)
@@ -178,8 +178,8 @@ public static async Task GetObjectMetadataAsync(
178178
/// </summary>
179179
/// <param name="client">The initialized S3 client object used to call
180180
/// CopyObjectAsync.</param>
181-
/// <param name="bucketName">The S3 bucket containing the object we
182-
/// wish to copy.</param>
181+
/// <param name="bucketName">The S3 bucket containing the object
182+
/// to copy.</param>
183183
/// <param name="keyName">The name of the object to copy.</param>
184184
/// <param name="copyTargetKeyName">The S3 bucket to which the object
185185
/// will be copied.</param>

dotnetv3/S3/ServerAccessLoggingExample/ServerAccessLoggingExample/ServerAccessLogging.cs

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -25,10 +25,10 @@ public static async Task Main()
2525
string logBucketName = "doc-example-logs-bucket";
2626
string logObjectKeyPrefix = "Logs";
2727

28-
// If the AWS region defined for your default user is different
29-
// from the AWS regsion where your Amazon S3 bucket is located,
30-
// pass the AWS Region name to the S3 client object's constructor.
31-
// For example, RegionEndpoint.USWest2 or RegionEndpoint.USEast2.
28+
// If the AWS Region defined for your default user is different
29+
// from the Regsion where your Amazon S3 bucket is located,
30+
// pass the Region name to the S3 client object's constructor.
31+
// For example: RegionEndpoint.USWest2 or RegionEndpoint.USEast2.
3232
IAmazonS3 client = new AmazonS3Client();
3333

3434
try

dotnetv3/S3/ServerSideEncryptionExample/ServerSideEncryptionExample/ServerSideEncryption.cs

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -21,10 +21,10 @@ public static async Task Main()
2121
string bucketName = "doc-example-bucket";
2222
string keyName = "samplefile.txt";
2323

24-
// If the AWS region defined for your default user is different
25-
// from the AWS regsion where your Amazon S3 bucket is located,
26-
// pass the AWS Region name to the S3 client object's constructor.
27-
// For example, RegionEndpoint.USWest2.
24+
// If the AWS Region defined for your default user is different
25+
// from the Regsion where your Amazon S3 bucket is located,
26+
// pass the Region name to the S3 client object's constructor.
27+
// For example: RegionEndpoint.USWest2.
2828
IAmazonS3 client = new AmazonS3Client();
2929

3030
await WritingAnObjectAsync(client, bucketName, keyName);

dotnetv3/S3/UploadUsingPresignedURLExample/UploadUsingPresignedURLExample/UploadUsingPresignedURL.cs

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -28,10 +28,10 @@ public static void Main()
2828
// Specify how long the signed URL will be valid in hours.
2929
double timeoutDuration = 12;
3030

31-
// If the AWS region defined for your default user is different
32-
// from the AWS regsion where your Amazon S3 bucket is located,
33-
// pass the AWS Region name to the S3 client object's constructor.
34-
// For example, RegionEndpoint.USWest2.
31+
// If the AWS Region defined for your default user is different
32+
// from the Regsion where your Amazon S3 bucket is located,
33+
// pass the Region name to the S3 client object's constructor.
34+
// For example: RegionEndpoint.USWest2.
3535
IAmazonS3 client = new AmazonS3Client();
3636

3737
var url = GeneratePreSignedURL(client, bucketName, keyName, timeoutDuration);
@@ -55,7 +55,7 @@ public static void Main()
5555
/// file you want to upload.</param>
5656
/// <param name="url">The presigned URL that will be used to upload the
5757
/// file to the S3 bucket.</param>
58-
/// <returns>A boolean value indicating the success or failure of the
58+
/// <returns>A Boolean value indicating the success or failure of the
5959
/// operation, based on the HttpWebResponse.</returns>
6060
public static bool UploadObject(string filePath, string url)
6161
{

0 commit comments

Comments
 (0)