Skip to main content

ParallelModelBlobClient.UploadAsync method

Uploads a local file as a new blob associated with the specified model.

public Task<ParallelModelResponse> UploadAsync(Guid modelId, string filePath, string encryptionKey,
string name, string description = "", string recordType = "Generic", string accessTier = "Hot",
IEnumerable<string>? tags = null, TimeSpan? timeout = default,
CancellationToken cancellationToken = default)
parameterdescription
modelIdThe non-empty identifier of the model.
filePathThe path of the local file to upload.
encryptionKeyThe encryption key supplied with the blob request.
nameThe name of the blob record.
descriptionThe description of the blob record, which may be empty.
recordTypeThe record type of the blob.
accessTierThe storage access tier of the blob.
tagsThe tags associated with the blob, if provided.
timeoutThe optional timeout for the operation.
cancellationTokenThe token used to cancel the operation.

Return Value​

A task containing the upload response.

Exceptions​

exceptioncondition
ParallelModelConfigurationExceptionThe model identifier is empty or the request configuration is invalid.
ParallelModelFileTransferExceptionThe source file path is invalid, the file does not exist, or the file cannot be read.

See Also​