Class UploadPartRequest
The parameters to request upload of a part in a multipart upload operation.
public class UploadPartRequest : AmazonWebServiceRequest
- Inheritance
-
UploadPartRequest
Remarks
If PartSize is not specified then the rest of the content from the file or stream will be sent to Amazon S3.
You must set either the FilePath or InputStream. If FilePath is set then the FilePosition property must be set.
Constructors
UploadPartRequest()
public UploadPartRequest()
Properties
BucketName
The name of the bucket to which the multipart upload was initiated.
When using this API with an access point, you must direct requests to the access point hostname. The access point hostname takes the form AccessPointName-AccountId.s3-accesspoint.Region.amazonaws.com. When using this operation with an access point through the AWS SDKs, you provide the access point ARN in place of the bucket name. For more information about access point ARNs, see Using Access Points in the Amazon Simple Storage Service Developer Guide.
When using this API with Amazon S3 on Outposts, you must direct requests to the S3 on Outposts hostname. The S3 on Outposts hostname takes the form AccessPointName-AccountId.outpostID.s3-outposts.Region.amazonaws.com. When using this operation using S3 on Outposts through the AWS SDKs, you provide the Outposts bucket ARN in place of the bucket name. For more information about S3 on Outposts ARNs, see Using S3 on Outposts in the Amazon Simple Storage Service Developer Guide.
public string BucketName { get; set; }
Property Value
DisableMD5Stream
WARNING: Setting DisableMD5Stream to true disables the MD5 data integrity check on this request.
When true, MD5Stream will not be used in the upload request. This may increase upload performance under high CPU loads. The default value is null. When null, the AWSConfigsS3.DisableMD5Stream property value will be used.
MD5Stream, SigV4 payload signing, and HTTPS each provide some data integrity verification. If DisableMD5Stream is true and DisablePayloadSigning is true, then the possibility of data corruption is completely dependant on HTTPS being the only remaining source of data integrity verification.
public bool? DisableMD5Stream { get; set; }
Property Value
- bool?
DisablePayloadSigning
WARNING: Setting DisablePayloadSigning to true disables the SigV4 payload signing data integrity check on this request.
If using SigV4, the DisablePayloadSigning flag controls if the payload should be signed on a request by request basis. By default this flag is null which will use the default client behavior. The default client behavior is to sign the payload. When DisablePayloadSigning is true, the request will be signed with an UNSIGNED-PAYLOAD value. Setting DisablePayloadSigning to true requires that the request is sent over a HTTPS connection.
Under certain circumstances, such as uploading to S3 while using MD5 hashing, it may be desireable to use UNSIGNED-PAYLOAD to decrease signing CPU usage. This flag only applies to Amazon S3 PutObject and UploadPart requests.
MD5Stream, SigV4 payload signing, and HTTPS each provide some data integrity verification. If DisableMD5Stream is true and DisablePayloadSigning is true, then the possibility of data corruption is completely dependant on HTTPS being the only remaining source of data integrity verification.
public bool? DisablePayloadSigning { get; set; }
Property Value
- bool?
Expect100Continue
Overriden to turn on Expect 100 continue.
protected override bool Expect100Continue { get; }
Property Value
ExpectedBucketOwner
The account id of the expected bucket owner. If the bucket is owned by a different account, the request will fail with an HTTP 403 (Access Denied) error.
public string ExpectedBucketOwner { get; set; }
Property Value
FilePath
Full path and name of a file from which the content for the part is retrieved.
For WinRT and Windows Phone this property must be in the form of "ms-appdata:///local/file.txt".
public string FilePath { get; set; }
Property Value
FilePosition
Position in the file specified by FilePath from which to retrieve the content of the part. This field is required when a file path is specified. It is ignored when using the InputStream property.
public long FilePosition { get; set; }
Property Value
IncludeSHA256Header
Overriden to turn off sending SHA256 header.
protected override bool IncludeSHA256Header { get; }
Property Value
InputStream
Input stream for the request; content for the request will be read from the stream.
public Stream InputStream { get; set; }
Property Value
IsLastPart
Caller needs to set this to true when uploading the last part. This property only needs to be set when using the AmazonS3EncryptionClient.
public bool IsLastPart { get; set; }
Property Value
Key
The key of the object.
public string Key { get; set; }
Property Value
Remarks
This property will be used as part of the resource path of the HTTP request. In .NET the System.Uri class is used to construct the uri for the request. The System.Uri class will canonicalize the uri string by compacting characters like "..". /// For example an object key of "foo/../bar/file.txt" will be transformed into "bar/file.txt" because the ".." is interpreted as use parent directory. For further information view the documentation for the Uri class: https://docs.microsoft.com/en-us/dotnet/api/system.uri
MD5Digest
An MD5 digest for the part.
public string MD5Digest { get; set; }
Property Value
PartNumber
Part number of part being uploaded.
public int PartNumber { get; set; }
Property Value
PartSize
The size of the part to be uploaded.
public long PartSize { get; set; }
Property Value
RequestPayer
Confirms that the requester knows that she or he will be charged for the list objects request. Bucket owners need not specify this parameter in their requests.
public RequestPayer RequestPayer { get; set; }
Property Value
ServerSideEncryptionCustomerMethod
The Server-side encryption algorithm to be used with the customer provided key.
public ServerSideEncryptionCustomerMethod ServerSideEncryptionCustomerMethod { get; set; }
Property Value
ServerSideEncryptionCustomerProvidedKey
The base64-encoded encryption key for Amazon S3 to use to encrypt the object
Using the encryption key you provide as part of your request Amazon S3 manages both the encryption, as it writes to disks, and decryption, when you access your objects. Therefore, you don't need to maintain any data encryption code. The only thing you do is manage the encryption keys you provide.
When you retrieve an object, you must provide the same encryption key as part of your request. Amazon S3 first verifies the encryption key you provided matches, and then decrypts the object before returning the object data to you.
Important: Amazon S3 does not store the encryption key you provide.
public string ServerSideEncryptionCustomerProvidedKey { get; set; }
Property Value
ServerSideEncryptionCustomerProvidedKeyMD5
The MD5 of the customer encryption key specified in the ServerSideEncryptionCustomerProvidedKey property. The MD5 is base 64 encoded. This field is optional, the SDK will calculate the MD5 if this is not set.
public string ServerSideEncryptionCustomerProvidedKeyMD5 { get; set; }
Property Value
StreamTransferProgress
Attach a callback that will be called as data is being sent to the AWS Service.
public EventHandler<StreamTransferProgressArgs> StreamTransferProgress { get; set; }
Property Value
- EventHandler<StreamTransferProgressArgs>
UploadId
Upload ID identifying the multipart upload whose part is being uploaded.
public string UploadId { get; set; }
Property Value
UseChunkEncoding
If this value is set to true then a chunked encoding upload will be used for the request. Default: true.
public bool UseChunkEncoding { get; set; }