You are viewing documentation for version 2 of the AWS SDK for Ruby. Version 3 documentation can be found here.
Class: Aws::Glacier::MultipartUpload
- Inherits:
-
Resources::Resource
- Object
- Resources::Resource
- Aws::Glacier::MultipartUpload
- Defined in:
- (unknown)
Instance Attribute Summary collapse
-
#account_id ⇒ String
readonly
-
#archive_description ⇒ String
readonly
The description of the archive that was specified in the Initiate Multipart Upload request.
-
#creation_date ⇒ Time
readonly
-
#id ⇒ String
readonly
-
#multipart_upload_id ⇒ String
readonly
The ID of a multipart upload.
-
#part_size_in_bytes ⇒ Integer
readonly
The part size, in bytes, specified in the Initiate Multipart Upload request.
-
#vault_arn ⇒ String
readonly
The Amazon Resource Name (ARN) of the vault that contains the archive.
-
#vault_name ⇒ String
readonly
Attributes inherited from Resources::Resource
Instance Method Summary collapse
-
#abort ⇒ Struct
This operation aborts a multipart upload identified by the upload ID.
After the Abort Multipart Upload request succeeds, you cannot upload any more parts to the multipart upload or complete the multipart upload.
-
#complete(options = {}) ⇒ Types::ArchiveCreationOutput
You call this operation to inform Amazon S3 Glacier (Glacier) that all the archive parts have been uploaded and that Glacier can now assemble the archive from the uploaded parts.
-
#initialize ⇒ Object
constructor
-
#parts(options = {}) ⇒ Types::ListPartsOutput
This operation lists the parts of an archive that have been uploaded in a specific multipart upload.
-
#upload_part(options = {}) ⇒ Types::UploadMultipartPartOutput
This operation uploads a part of an archive.
-
#vault ⇒ Vault
Methods inherited from Resources::Resource
add_data_attribute, add_identifier, #data, data_attributes, #data_loaded?, identifiers, #load, #wait_until
Methods included from Resources::OperationMethods
#add_batch_operation, #add_operation, #batch_operation, #batch_operation_names, #batch_operations, #operation, #operation_names, #operations
Constructor Details
#initialize(account_id, vault_name, id, options = {}) ⇒ Object #initialize(options = {}) ⇒ Object
Instance Attribute Details
#account_id ⇒ String (readonly)
#archive_description ⇒ String (readonly)
The description of the archive that was specified in the Initiate Multipart Upload request.
#creation_date ⇒ Time (readonly)
#id ⇒ String (readonly)
#multipart_upload_id ⇒ String (readonly)
The ID of a multipart upload.
#part_size_in_bytes ⇒ Integer (readonly)
The part size, in bytes, specified in the Initiate Multipart Upload request. This is the size of all the parts in the upload except the last part, which may be smaller than this size.
#vault_arn ⇒ String (readonly)
The Amazon Resource Name (ARN) of the vault that contains the archive.
#vault_name ⇒ String (readonly)
Instance Method Details
#abort ⇒ Struct
This operation aborts a multipart upload identified by the upload ID.
After the Abort Multipart Upload request succeeds, you cannot upload any more parts to the multipart upload or complete the multipart upload. Aborting a completed upload fails. However, aborting an already-aborted upload will succeed, for a short time. For more information about uploading a part and completing a multipart upload, see UploadMultipartPart and CompleteMultipartUpload.
This operation is idempotent.
An AWS account has full permission to perform all operations (actions). However, AWS Identity and Access Management (IAM) users don't have any permissions by default. You must grant them explicit permission to perform specific actions. For more information, see Access Control Using AWS Identity and Access Management (IAM).
For conceptual information and underlying REST API, see Working with Archives in Amazon S3 Glacier and Abort Multipart Upload in the Amazon Glacier Developer Guide.
#complete(options = {}) ⇒ Types::ArchiveCreationOutput
You call this operation to inform Amazon S3 Glacier (Glacier) that all the archive parts have been uploaded and that Glacier can now assemble the archive from the uploaded parts. After assembling and saving the archive to the vault, Glacier returns the URI path of the newly created archive resource. Using the URI path, you can then access the archive. After you upload an archive, you should save the archive ID returned to retrieve the archive at a later point. You can also get the vault inventory to obtain a list of archive IDs in a vault. For more information, see InitiateJob.
In the request, you must include the computed SHA256 tree hash of the entire archive you have uploaded. For information about computing a SHA256 tree hash, see Computing Checksums. On the server side, Glacier also constructs the SHA256 tree hash of the assembled archive. If the values match, Glacier saves the archive to the vault; otherwise, it returns an error, and the operation fails. The ListParts operation returns a list of parts uploaded for a specific multipart upload. It includes checksum information for each uploaded part that can be used to debug a bad checksum issue.
Additionally, Glacier also checks for any missing content ranges when assembling the archive, if missing content ranges are found, Glacier returns an error and the operation fails.
Complete Multipart Upload is an idempotent operation. After your first successful complete multipart upload, if you call the operation again within a short period, the operation will succeed and return the same archive ID. This is useful in the event you experience a network issue that causes an aborted connection or receive a 500 server error, in which case you can repeat your Complete Multipart Upload request and get the same archive ID without creating duplicate archives. Note, however, that after the multipart upload completes, you cannot call the List Parts operation and the multipart upload will not appear in List Multipart Uploads response, even if idempotent complete is possible.
An AWS account has full permission to perform all operations (actions). However, AWS Identity and Access Management (IAM) users don't have any permissions by default. You must grant them explicit permission to perform specific actions. For more information, see Access Control Using AWS Identity and Access Management (IAM).
For conceptual information and underlying REST API, see Uploading Large Archives in Parts (Multipart Upload) and Complete Multipart Upload in the Amazon Glacier Developer Guide.
#parts(options = {}) ⇒ Types::ListPartsOutput
This operation lists the parts of an archive that have been uploaded in a specific multipart upload. You can make this request at any time during an in-progress multipart upload before you complete the upload (see CompleteMultipartUpload. List Parts returns an error for completed uploads. The list returned in the List Parts response is sorted by part range.
The List Parts operation supports pagination. By default, this operation returns up to 50 uploaded parts in the response. You should always check the response for a marker
at which to continue the list; if there are no more items the marker
is null
. To return a list of parts that begins at a specific part, set the marker
request parameter to the value you obtained from a previous List Parts request. You can also limit the number of parts returned in the response by specifying the limit
parameter in the request.
An AWS account has full permission to perform all operations (actions). However, AWS Identity and Access Management (IAM) users don't have any permissions by default. You must grant them explicit permission to perform specific actions. For more information, see Access Control Using AWS Identity and Access Management (IAM).
For conceptual information and the underlying REST API, see Working with Archives in Amazon S3 Glacier and List Parts in the Amazon Glacier Developer Guide.
#upload_part(options = {}) ⇒ Types::UploadMultipartPartOutput
This operation uploads a part of an archive. You can upload archive parts in any order. You can also upload them in parallel. You can upload up to 10,000 parts for a multipart upload.
Amazon Glacier rejects your upload part request if any of the following conditions is true:
-
SHA256 tree hash does not matchTo ensure that part data is not corrupted in transmission, you compute a SHA256 tree hash of the part and include it in your request. Upon receiving the part data, Amazon S3 Glacier also computes a SHA256 tree hash. If these hash values don't match, the operation fails. For information about computing a SHA256 tree hash, see Computing Checksums.
-
Part size does not matchThe size of each part except the last must match the size specified in the corresponding InitiateMultipartUpload request. The size of the last part must be the same size as, or smaller than, the specified size.
If you upload a part whose size is smaller than the part size you specified in your initiate multipart upload request and that part is not the last part, then the upload part request will succeed. However, the subsequent Complete Multipart Upload request will fail.
-
Range does not alignThe byte range value in the request does not align with the part size specified in the corresponding initiate request. For example, if you specify a part size of 4194304 bytes (4 MB), then 0 to 4194303 bytes (4 MB - 1) and 4194304 (4 MB) to 8388607 (8 MB - 1) are valid part ranges. However, if you set a range value of 2 MB to 6 MB, the range does not align with the part size and the upload will fail.
This operation is idempotent. If you upload the same part multiple times, the data included in the most recent request overwrites the previously uploaded data.
An AWS account has full permission to perform all operations (actions). However, AWS Identity and Access Management (IAM) users don't have any permissions by default. You must grant them explicit permission to perform specific actions. For more information, see Access Control Using AWS Identity and Access Management (IAM).
For conceptual information and underlying REST API, see Uploading Large Archives in Parts (Multipart Upload) and Upload Part in the Amazon Glacier Developer Guide.