0
votes

I wish to use the aws sdk cpp async api's for s3 in my application. However I am not able to find documentation for the same. I have been through https://github.com/awsdocs/aws-doc-sdk-examples/tree/master/cpp/example_code/s3 but there are no examples which include async api's.

For example I am trying to use the PutObjectAsync api. According the api reference guide given here https://sdk.amazonaws.com/cpp/api/LATEST/class_aws_1_1_s3_1_1_s3_client.html#aee8d39c350c5bb66a8d1edcc18df2b78 you need to form the PutObjectRequest, PutObjectResponseReceivedHandler and AsyncCallerContext.

Here I didn't understood how to form the PutObjectResponseReceivedHandler and AsyncCallerContext. Can someone please guide me through it.

1

1 Answers

2
votes

The AWS Code Sample Catalog on GitHub now includes a C++ example that demonstrates how to upload a file to Amazon S3 asynchronously.

The source code can be viewed at https://github.com/awsdocs/aws-doc-sdk-examples/blob/master/cpp/example_code/s3/put_object_async.cpp