I am new to Amazon AWS and Glacier.
I am trying to write a WPF Windows-based C# client that uploads my archived backup data to the glacier cloud.
However, the API reference don’t seem to offer a cancel command. Only upload, download, list.
What I’m trying to do is run each upload operation (which can take 1 hour or more with large files) asynchronously using TPL.
However I want the upload to be cancellable, which .NET 4.5 would support nicely, but the Amazon API does not.
Is there a way to do that anyway?
Thanks.
The recommended way to handle your scenario in Amazon Glacier (and Amazon S3 as well btw.) is to Upload archives in parts via Multipart Upload, see Uploading an Archive in Amazon Glacier:
Uploading Large Archives in Parts (Multipart Upload) provides the details on the latter, specifically regarding Complete (or Abort) Multipart Upload:
So you still can’t abort the uploads of parts that are in progress as such, thus the key for the desired user experience and/or network bandwidth reduction is choosing a small enough part size.
Depending on your use case you might also want to check into List Multipart Uploads (GET multipart-uploads):