diff --git a/eng/.docsettings.yml b/eng/.docsettings.yml
index 3ae4c9aa409d4..4fb91b2a5c7e7 100644
--- a/eng/.docsettings.yml
+++ b/eng/.docsettings.yml
@@ -75,6 +75,9 @@ known_content_issues:
- ['sdk/cosmos/changelog/README.md', '#3113']
- ['sdk/cosmos/microsoft-azure-cosmos-benchmark/README.md', '#3113']
- ['sdk/cosmos/README.md', '#3113']
+ - ['sdk/storage/azure-storage-blob/swagger/README.md', '#3113']
+ - ['sdk/storage/azure-storage-queue/swagger/README.md', '#3113']
+ - ['sdk/storage/azure-storage-file/swagger/README.md', '#3113']
package_indexing_exclusion_list:
- azure-loganalytics-sample
- azure-applicationinsights-query-sample
diff --git a/eng/code-quality-reports/src/main/resources/spotbugs/spotbugs-exclude.xml b/eng/code-quality-reports/src/main/resources/spotbugs/spotbugs-exclude.xml
index 6cfdbbd519233..bf64bafa0c431 100755
--- a/eng/code-quality-reports/src/main/resources/spotbugs/spotbugs-exclude.xml
+++ b/eng/code-quality-reports/src/main/resources/spotbugs/spotbugs-exclude.xml
@@ -65,6 +65,8 @@
+
+
diff --git a/sdk/storage/azure-storage-blob/src/main/java/com/azure/storage/blob/AppendBlobAsyncClient.java b/sdk/storage/azure-storage-blob/src/main/java/com/azure/storage/blob/AppendBlobAsyncClient.java
index 9cf6c224c0d3b..d2d20d34c58f6 100644
--- a/sdk/storage/azure-storage-blob/src/main/java/com/azure/storage/blob/AppendBlobAsyncClient.java
+++ b/sdk/storage/azure-storage-blob/src/main/java/com/azure/storage/blob/AppendBlobAsyncClient.java
@@ -94,8 +94,8 @@ public Mono> create(BlobHTTPHeaders headers, Metadata m
accessConditions = (accessConditions == null) ? new BlobAccessConditions() : accessConditions;
return postProcessResponse(this.azureBlobStorage.appendBlobs().createWithRestResponseAsync(null,
- null, 0, null, metadata, null, null,
- null, null, headers, accessConditions.leaseAccessConditions(),
+ null, 0, null, metadata, null, null, null,
+ null, null, headers, accessConditions.leaseAccessConditions(), null,
accessConditions.modifiedAccessConditions(), Context.NONE))
.map(rb -> new SimpleResponse<>(rb, new AppendBlobItem(rb.deserializedHeaders())));
}
@@ -144,10 +144,10 @@ public Mono> appendBlock(Flux data, long lengt
: appendBlobAccessConditions;
return postProcessResponse(this.azureBlobStorage.appendBlobs().appendBlockWithRestResponseAsync(
- null, null, data, length, null, null,
+ null, null, data, length, null, null, null,
null, null, null, null,
appendBlobAccessConditions.leaseAccessConditions(),
- appendBlobAccessConditions.appendPositionAccessConditions(),
+ appendBlobAccessConditions.appendPositionAccessConditions(), null,
appendBlobAccessConditions.modifiedAccessConditions(), Context.NONE))
.map(rb -> new SimpleResponse<>(rb, new AppendBlobItem(rb.deserializedHeaders())));
}
@@ -201,7 +201,7 @@ public Mono> appendBlockFromUrl(URL sourceURL, BlobRang
return postProcessResponse(
this.azureBlobStorage.appendBlobs().appendBlockFromUrlWithRestResponseAsync(null, null,
- sourceURL, 0, sourceRange.toString(), sourceContentMD5, null, null,
+ sourceURL, 0, sourceRange.toString(), sourceContentMD5, null, null, null, null,
destAccessConditions.leaseAccessConditions(),
destAccessConditions.appendPositionAccessConditions(),
destAccessConditions.modifiedAccessConditions(), sourceAccessConditions, Context.NONE))
diff --git a/sdk/storage/azure-storage-blob/src/main/java/com/azure/storage/blob/BlobAsyncClient.java b/sdk/storage/azure-storage-blob/src/main/java/com/azure/storage/blob/BlobAsyncClient.java
index b4a5e38668c67..53801a50018c2 100644
--- a/sdk/storage/azure-storage-blob/src/main/java/com/azure/storage/blob/BlobAsyncClient.java
+++ b/sdk/storage/azure-storage-blob/src/main/java/com/azure/storage/blob/BlobAsyncClient.java
@@ -13,6 +13,7 @@
import com.azure.storage.blob.implementation.AzureBlobStorageBuilder;
import com.azure.storage.blob.implementation.AzureBlobStorageImpl;
import com.azure.storage.blob.models.AccessTier;
+import com.azure.storage.blob.models.AccessTierRequired;
import com.azure.storage.blob.models.BlobAccessConditions;
import com.azure.storage.blob.models.BlobHTTPHeaders;
import com.azure.storage.blob.models.BlobRange;
@@ -245,7 +246,7 @@ public Mono> startCopyFromURL(URL sourceURL, Metadata metadata,
.sourceIfNoneMatch(sourceModifiedAccessConditions.ifNoneMatch());
return postProcessResponse(this.azureBlobStorage.blobs().startCopyFromURLWithRestResponseAsync(
- null, null, sourceURL, null, metadata, null, sourceConditions,
+ null, null, sourceURL, null, metadata, null, null, null, null, sourceConditions,
destAccessConditions.modifiedAccessConditions(), destAccessConditions.leaseAccessConditions(), Context.NONE))
.map(rb -> new SimpleResponse<>(rb, rb.deserializedHeaders().copyId()));
}
@@ -340,7 +341,7 @@ public Mono> copyFromURL(URL copySource, Metadata metadata, Mod
.sourceIfNoneMatch(sourceModifiedAccessConditions.ifNoneMatch());
return postProcessResponse(this.azureBlobStorage.blobs().copyFromURLWithRestResponseAsync(
- null, null, copySource, null, metadata, null, sourceConditions,
+ null, null, copySource, null, metadata, null, null, null, sourceConditions,
destAccessConditions.modifiedAccessConditions(), destAccessConditions.leaseAccessConditions(), Context.NONE))
.map(rb -> new SimpleResponse<>(rb, rb.deserializedHeaders().copyId()));
}
@@ -413,7 +414,7 @@ Mono download(BlobRange range, BlobAccessConditions acces
// TODO: range is BlobRange but expected as String
// TODO: figure out correct response
return postProcessResponse(this.azureBlobStorage.blobs().downloadWithRestResponseAsync(
- null, null, snapshot, null, null, range.toHeaderValue(), getMD5,
+ null, null, snapshot, null, null, range.toHeaderValue(), getMD5, null,
null, null, null, null,
accessConditions.leaseAccessConditions(), accessConditions.modifiedAccessConditions(), Context.NONE))
// Convert the autorest response to a DownloadAsyncResponse, which enable reliable download.
@@ -691,7 +692,7 @@ public Mono setMetadata(Metadata metadata, BlobAccessConditions ac
return postProcessResponse(this.azureBlobStorage.blobs().setMetadataWithRestResponseAsync(
null, null, null, metadata, null, null,
- null, null, accessConditions.leaseAccessConditions(),
+ null, null, accessConditions.leaseAccessConditions(), null,
accessConditions.modifiedAccessConditions(), Context.NONE))
.map(VoidResponse::new);
}
@@ -734,7 +735,7 @@ public Mono> createSnapshot(Metadata metadata, BlobAcc
return postProcessResponse(this.azureBlobStorage.blobs().createSnapshotWithRestResponseAsync(
null, null, null, metadata, null, null,
- null, null, accessConditions.modifiedAccessConditions(),
+ null, null, null, accessConditions.modifiedAccessConditions(),
accessConditions.leaseAccessConditions(), Context.NONE))
.map(rb -> new SimpleResponse<>(rb, this.getSnapshotClient(rb.deserializedHeaders().snapshot())));
}
@@ -779,9 +780,10 @@ public Mono setTier(AccessTier tier) {
*/
public Mono setTier(AccessTier tier, LeaseAccessConditions leaseAccessConditions) {
Utility.assertNotNull("tier", tier);
+ AccessTierRequired accessTierRequired = AccessTierRequired.fromString(tier.toString());
return postProcessResponse(this.azureBlobStorage.blobs().setTierWithRestResponseAsync(
- null, null, tier, null, null, leaseAccessConditions, Context.NONE))
+ null, null, accessTierRequired, null, null, null, leaseAccessConditions, Context.NONE))
.map(VoidResponse::new);
}
diff --git a/sdk/storage/azure-storage-blob/src/main/java/com/azure/storage/blob/BlockBlobAsyncClient.java b/sdk/storage/azure-storage-blob/src/main/java/com/azure/storage/blob/BlockBlobAsyncClient.java
index 162bb1917b612..91875e7a2fd55 100644
--- a/sdk/storage/azure-storage-blob/src/main/java/com/azure/storage/blob/BlockBlobAsyncClient.java
+++ b/sdk/storage/azure-storage-blob/src/main/java/com/azure/storage/blob/BlockBlobAsyncClient.java
@@ -152,8 +152,8 @@ public Mono> upload(Flux data, long length, Blo
accessConditions = accessConditions == null ? new BlobAccessConditions() : accessConditions;
return postProcessResponse(this.azureBlobStorage.blockBlobs().uploadWithRestResponseAsync(null,
- null, data, length, null, metadata, null, null,
- null, null, headers, accessConditions.leaseAccessConditions(),
+ null, data, length, null, metadata, null, null, null,
+ null, null, null, headers, accessConditions.leaseAccessConditions(), null,
accessConditions.modifiedAccessConditions(), Context.NONE))
.map(rb -> new SimpleResponse<>(rb, new BlockBlobItem(rb.deserializedHeaders())));
}
@@ -297,8 +297,8 @@ public Mono stageBlock(String base64BlockID, Flux data,
public Mono stageBlock(String base64BlockID, Flux data, long length,
LeaseAccessConditions leaseAccessConditions) {
return postProcessResponse(this.azureBlobStorage.blockBlobs().stageBlockWithRestResponseAsync(null,
- null, base64BlockID, length, data, null, null, null,
- null, null, null, leaseAccessConditions, Context.NONE))
+ null, base64BlockID, length, data, null, null, null, null,
+ null, null, null, leaseAccessConditions, null, Context.NONE))
.map(VoidResponse::new);
}
@@ -359,9 +359,9 @@ public Mono stageBlockFromURL(String base64BlockID, URL sourceURL,
return postProcessResponse(
this.azureBlobStorage.blockBlobs().stageBlockFromURLWithRestResponseAsync(null, null,
- base64BlockID, 0, sourceURL, sourceRange.toHeaderValue(), sourceContentMD5, null,
+ base64BlockID, 0, sourceURL, sourceRange.toHeaderValue(), sourceContentMD5, null, null,
null, null, null, null,
- leaseAccessConditions, sourceModifiedAccessConditions, Context.NONE))
+ leaseAccessConditions, null, sourceModifiedAccessConditions, Context.NONE))
.map(VoidResponse::new);
}
@@ -456,9 +456,9 @@ public Mono> commitBlockList(List base64BlockIDs
accessConditions = accessConditions == null ? new BlobAccessConditions() : accessConditions;
return postProcessResponse(this.azureBlobStorage.blockBlobs().commitBlockListWithRestResponseAsync(
- null, null, new BlockLookupList().latest(base64BlockIDs), null, metadata,
- null, null, null, null, headers,
- accessConditions.leaseAccessConditions(), accessConditions.modifiedAccessConditions(), Context.NONE))
+ null, null, new BlockLookupList().latest(base64BlockIDs), null, null, null, metadata, null,
+ null, null, null, null, null, headers,
+ accessConditions.leaseAccessConditions(), null, accessConditions.modifiedAccessConditions(), Context.NONE))
.map(rb -> new SimpleResponse<>(rb, new BlockBlobItem(rb.deserializedHeaders())));
}
}
diff --git a/sdk/storage/azure-storage-blob/src/main/java/com/azure/storage/blob/ContainerAsyncClient.java b/sdk/storage/azure-storage-blob/src/main/java/com/azure/storage/blob/ContainerAsyncClient.java
index 99b1524507bf1..a741b2c7dba23 100644
--- a/sdk/storage/azure-storage-blob/src/main/java/com/azure/storage/blob/ContainerAsyncClient.java
+++ b/sdk/storage/azure-storage-blob/src/main/java/com/azure/storage/blob/ContainerAsyncClient.java
@@ -278,7 +278,7 @@ public Mono create(Metadata metadata, PublicAccessType accessType)
metadata = metadata == null ? new Metadata() : metadata;
return postProcessResponse(this.azureBlobStorage.containers().createWithRestResponseAsync(
- null, null, metadata, accessType, null, Context.NONE))
+ null, null, metadata, accessType, null, null, null, Context.NONE))
.map(VoidResponse::new);
}
diff --git a/sdk/storage/azure-storage-blob/src/main/java/com/azure/storage/blob/PageBlobAsyncClient.java b/sdk/storage/azure-storage-blob/src/main/java/com/azure/storage/blob/PageBlobAsyncClient.java
index 944bb4ef8ff6c..57a98ebc22d1b 100644
--- a/sdk/storage/azure-storage-blob/src/main/java/com/azure/storage/blob/PageBlobAsyncClient.java
+++ b/sdk/storage/azure-storage-blob/src/main/java/com/azure/storage/blob/PageBlobAsyncClient.java
@@ -127,8 +127,8 @@ public Mono> create(long size, Long sequenceNumber, BlobH
metadata = metadata == null ? new Metadata() : metadata;
return postProcessResponse(this.azureBlobStorage.pageBlobs().createWithRestResponseAsync(null,
- null, 0, size, null, metadata, null, null,
- null, sequenceNumber, null, headers, accessConditions.leaseAccessConditions(),
+ null, 0, size, null, metadata, null, null, null,
+ null, sequenceNumber, null, headers, accessConditions.leaseAccessConditions(), null,
accessConditions.modifiedAccessConditions(), Context.NONE))
.map(rb -> new SimpleResponse<>(rb, new PageBlobItem(rb.deserializedHeaders())));
}
@@ -189,9 +189,9 @@ public Mono> uploadPages(PageRange pageRange, Flux new SimpleResponse<>(rb, new PageBlobItem(rb.deserializedHeaders())));
}
@@ -272,7 +272,7 @@ public Mono> uploadPagesFromURL(PageRange range, URL sour
destAccessConditions = destAccessConditions == null ? new PageBlobAccessConditions() : destAccessConditions;
return postProcessResponse(this.azureBlobStorage.pageBlobs().uploadPagesFromURLWithRestResponseAsync(
- null, null, sourceURL, sourceRangeString, 0, rangeString, sourceContentMD5,
+ null, null, sourceURL, sourceRangeString, 0, rangeString, sourceContentMD5, null,
null, null, destAccessConditions.leaseAccessConditions(),
destAccessConditions.sequenceNumberAccessConditions(), destAccessConditions.modifiedAccessConditions(),
sourceAccessConditions, Context.NONE))
diff --git a/sdk/storage/azure-storage-blob/src/main/java/com/azure/storage/blob/implementation/AppendBlobsImpl.java b/sdk/storage/azure-storage-blob/src/main/java/com/azure/storage/blob/implementation/AppendBlobsImpl.java
index 3439bb917017e..9f220878e06d3 100644
--- a/sdk/storage/azure-storage-blob/src/main/java/com/azure/storage/blob/implementation/AppendBlobsImpl.java
+++ b/sdk/storage/azure-storage-blob/src/main/java/com/azure/storage/blob/implementation/AppendBlobsImpl.java
@@ -25,17 +25,19 @@
import com.azure.storage.blob.models.AppendBlobsCreateResponse;
import com.azure.storage.blob.models.AppendPositionAccessConditions;
import com.azure.storage.blob.models.BlobHTTPHeaders;
+import com.azure.storage.blob.models.CustomerProvidedKeyInfo;
import com.azure.storage.blob.models.EncryptionAlgorithmType;
import com.azure.storage.blob.models.LeaseAccessConditions;
import com.azure.storage.blob.models.ModifiedAccessConditions;
import com.azure.storage.blob.models.SourceModifiedAccessConditions;
import com.azure.storage.blob.models.StorageErrorException;
import io.netty.buffer.ByteBuf;
+import reactor.core.publisher.Flux;
+import reactor.core.publisher.Mono;
+
import java.net.URL;
import java.time.OffsetDateTime;
import java.util.Map;
-import reactor.core.publisher.Flux;
-import reactor.core.publisher.Mono;
/**
* An instance of this class provides access to all the operations defined in
@@ -72,17 +74,17 @@ private interface AppendBlobsService {
@Put("{containerName}/{blob}")
@ExpectedResponses({201})
@UnexpectedResponseExceptionType(StorageErrorException.class)
- Mono create(@PathParam("containerName") String containerName, @PathParam("blob") String blob, @HostParam("url") String url, @QueryParam("timeout") Integer timeout, @HeaderParam("Content-Length") long contentLength, @HeaderParam("x-ms-meta-") Map metadata, @QueryParam("x-ms-encryption-key") String encryptionKey, @QueryParam("x-ms-encryption-key-sha256") String encryptionKeySha256, @QueryParam("x-ms-encryption-algorithm") EncryptionAlgorithmType encryptionAlgorithm, @HeaderParam("x-ms-version") String version, @HeaderParam("x-ms-client-request-id") String requestId, @HeaderParam("x-ms-blob-type") String blobType, @HeaderParam("x-ms-blob-content-type") String blobContentType, @HeaderParam("x-ms-blob-content-encoding") String blobContentEncoding, @HeaderParam("x-ms-blob-content-language") String blobContentLanguage, @HeaderParam("x-ms-blob-content-md5") String blobContentMD5, @HeaderParam("x-ms-blob-cache-control") String blobCacheControl, @HeaderParam("x-ms-blob-content-disposition") String blobContentDisposition, @HeaderParam("x-ms-lease-id") String leaseId, @HeaderParam("If-Modified-Since") DateTimeRfc1123 ifModifiedSince, @HeaderParam("If-Unmodified-Since") DateTimeRfc1123 ifUnmodifiedSince, @HeaderParam("If-Match") String ifMatch, @HeaderParam("If-None-Match") String ifNoneMatch, Context context);
+ Mono create(@PathParam("containerName") String containerName, @PathParam("blob") String blob, @HostParam("url") String url, @QueryParam("timeout") Integer timeout, @HeaderParam("Content-Length") long contentLength, @HeaderParam("x-ms-meta-") Map metadata, @HeaderParam("x-ms-tags") String tags, @QueryParam("x-ms-encryption-key") String xMsEncryptionKey, @QueryParam("x-ms-encryption-key-sha256") String xMsEncryptionKeySha256, @QueryParam("x-ms-encryption-algorithm") EncryptionAlgorithmType xMsEncryptionAlgorithm, @HeaderParam("x-ms-version") String version, @HeaderParam("x-ms-client-request-id") String requestId, @HeaderParam("x-ms-blob-type") String blobType, @HeaderParam("x-ms-blob-content-type") String blobContentType, @HeaderParam("x-ms-blob-content-encoding") String blobContentEncoding, @HeaderParam("x-ms-blob-content-language") String blobContentLanguage, @HeaderParam("x-ms-blob-content-md5") String blobContentMD5, @HeaderParam("x-ms-blob-cache-control") String blobCacheControl, @HeaderParam("x-ms-blob-content-disposition") String blobContentDisposition, @HeaderParam("x-ms-lease-id") String leaseId, @QueryParam("x-ms-encryption-scope") String encryptionScope, @HeaderParam("If-Modified-Since") DateTimeRfc1123 ifModifiedSince, @HeaderParam("If-Unmodified-Since") DateTimeRfc1123 ifUnmodifiedSince, @HeaderParam("If-Match") String ifMatch, @HeaderParam("If-None-Match") String ifNoneMatch, Context context);
@Put("{containerName}/{blob}")
@ExpectedResponses({201})
@UnexpectedResponseExceptionType(StorageErrorException.class)
- Mono appendBlock(@PathParam("containerName") String containerName, @PathParam("blob") String blob, @HostParam("url") String url, @BodyParam("application/octet-stream") Flux body, @QueryParam("timeout") Integer timeout, @HeaderParam("Content-Length") long contentLength, @HeaderParam("Content-MD5") String transactionalContentMD5, @QueryParam("x-ms-encryption-key") String encryptionKey, @QueryParam("x-ms-encryption-key-sha256") String encryptionKeySha256, @QueryParam("x-ms-encryption-algorithm") EncryptionAlgorithmType encryptionAlgorithm, @HeaderParam("x-ms-version") String version, @HeaderParam("x-ms-client-request-id") String requestId, @QueryParam("comp") String comp, @HeaderParam("x-ms-lease-id") String leaseId, @HeaderParam("x-ms-blob-condition-maxsize") Long maxSize, @HeaderParam("x-ms-blob-condition-appendpos") Long appendPosition, @HeaderParam("If-Modified-Since") DateTimeRfc1123 ifModifiedSince, @HeaderParam("If-Unmodified-Since") DateTimeRfc1123 ifUnmodifiedSince, @HeaderParam("If-Match") String ifMatch, @HeaderParam("If-None-Match") String ifNoneMatch, Context context);
+ Mono appendBlock(@PathParam("containerName") String containerName, @PathParam("blob") String blob, @HostParam("url") String url, @BodyParam("application/octet-stream") Flux body, @QueryParam("timeout") Integer timeout, @HeaderParam("Content-Length") long contentLength, @HeaderParam("Content-MD5") String transactionalContentMD5, @HeaderParam("x-ms-content-crc64") String transactionalContentCrc64, @QueryParam("x-ms-encryption-key") String xMsEncryptionKey, @QueryParam("x-ms-encryption-key-sha256") String xMsEncryptionKeySha256, @QueryParam("x-ms-encryption-algorithm") EncryptionAlgorithmType xMsEncryptionAlgorithm, @HeaderParam("x-ms-version") String version, @HeaderParam("x-ms-client-request-id") String requestId, @QueryParam("comp") String comp, @HeaderParam("x-ms-lease-id") String leaseId, @HeaderParam("x-ms-blob-condition-maxsize") Long maxSize, @HeaderParam("x-ms-blob-condition-appendpos") Long appendPosition, @QueryParam("x-ms-encryption-scope") String encryptionScope, @HeaderParam("If-Modified-Since") DateTimeRfc1123 ifModifiedSince, @HeaderParam("If-Unmodified-Since") DateTimeRfc1123 ifUnmodifiedSince, @HeaderParam("If-Match") String ifMatch, @HeaderParam("If-None-Match") String ifNoneMatch, Context context);
@Put("{containerName}/{blob}")
@ExpectedResponses({201})
@UnexpectedResponseExceptionType(StorageErrorException.class)
- Mono appendBlockFromUrl(@PathParam("containerName") String containerName, @PathParam("blob") String blob, @HostParam("url") String url, @HeaderParam("x-ms-copy-source") URL copySource, @HeaderParam("x-ms-source-range") String sourceRange, @HeaderParam("x-ms-source-content-md5") String sourceContentMD5, @QueryParam("timeout") Integer timeout, @HeaderParam("Content-Length") long contentLength, @HeaderParam("x-ms-version") String version, @HeaderParam("x-ms-client-request-id") String requestId, @QueryParam("comp") String comp, @HeaderParam("x-ms-lease-id") String leaseId, @HeaderParam("x-ms-blob-condition-maxsize") Long maxSize, @HeaderParam("x-ms-blob-condition-appendpos") Long appendPosition, @HeaderParam("If-Modified-Since") DateTimeRfc1123 ifModifiedSince, @HeaderParam("If-Unmodified-Since") DateTimeRfc1123 ifUnmodifiedSince, @HeaderParam("If-Match") String ifMatch, @HeaderParam("If-None-Match") String ifNoneMatch, @HeaderParam("x-ms-source-if-modified-since") DateTimeRfc1123 sourceIfModifiedSince, @HeaderParam("x-ms-source-if-unmodified-since") DateTimeRfc1123 sourceIfUnmodifiedSince, @HeaderParam("x-ms-source-if-match") String sourceIfMatch, @HeaderParam("x-ms-source-if-none-match") String sourceIfNoneMatch, Context context);
+ Mono appendBlockFromUrl(@PathParam("containerName") String containerName, @PathParam("blob") String blob, @HostParam("url") String url, @HeaderParam("x-ms-copy-source") URL copySource, @HeaderParam("x-ms-source-range") String sourceRange, @HeaderParam("x-ms-source-content-md5") String sourceContentMD5, @HeaderParam("x-ms-source-content-crc64") String sourceContentcrc64, @QueryParam("timeout") Integer timeout, @HeaderParam("Content-Length") long contentLength, @HeaderParam("Content-MD5") String transactionalContentMD5, @HeaderParam("x-ms-version") String version, @HeaderParam("x-ms-client-request-id") String requestId, @QueryParam("comp") String comp, @HeaderParam("x-ms-lease-id") String leaseId, @HeaderParam("x-ms-blob-condition-maxsize") Long maxSize, @HeaderParam("x-ms-blob-condition-appendpos") Long appendPosition, @HeaderParam("If-Modified-Since") DateTimeRfc1123 ifModifiedSince, @HeaderParam("If-Unmodified-Since") DateTimeRfc1123 ifUnmodifiedSince, @HeaderParam("If-Match") String ifMatch, @HeaderParam("If-None-Match") String ifNoneMatch, @HeaderParam("x-ms-source-if-modified-since") DateTimeRfc1123 sourceIfModifiedSince, @HeaderParam("x-ms-source-if-unmodified-since") DateTimeRfc1123 sourceIfUnmodifiedSince, @HeaderParam("x-ms-source-if-match") String sourceIfMatch, @HeaderParam("x-ms-source-if-none-match") String sourceIfNoneMatch, Context context);
}
/**
@@ -99,9 +101,10 @@ private interface AppendBlobsService {
public Mono createWithRestResponseAsync(String containerName, String blob, long contentLength, Context context) {
final Integer timeout = null;
final Map metadata = null;
- final String encryptionKey = null;
- final String encryptionKeySha256 = null;
- final EncryptionAlgorithmType encryptionAlgorithm = null;
+ final String tags = null;
+ final String xMsEncryptionKey = null;
+ final String xMsEncryptionKeySha256 = null;
+ final EncryptionAlgorithmType xMsEncryptionAlgorithm = null;
final String requestId = null;
final String blobType = "AppendBlob";
final String blobContentType = null;
@@ -110,12 +113,13 @@ public Mono createWithRestResponseAsync(String contai
final String blobCacheControl = null;
final String blobContentDisposition = null;
final String leaseId = null;
+ final String encryptionScope = null;
final String ifMatch = null;
final String ifNoneMatch = null;
String blobContentMD5Converted = null;
DateTimeRfc1123 ifModifiedSinceConverted = null;
DateTimeRfc1123 ifUnmodifiedSinceConverted = null;
- return service.create(containerName, blob, this.client.getUrl(), timeout, contentLength, metadata, encryptionKey, encryptionKeySha256, encryptionAlgorithm, this.client.getVersion(), requestId, blobType, blobContentType, blobContentEncoding, blobContentLanguage, blobContentMD5Converted, blobCacheControl, blobContentDisposition, leaseId, ifModifiedSinceConverted, ifUnmodifiedSinceConverted, ifMatch, ifNoneMatch, context);
+ return service.create(containerName, blob, this.client.getUrl(), timeout, contentLength, metadata, tags, xMsEncryptionKey, xMsEncryptionKeySha256, xMsEncryptionAlgorithm, this.client.getVersion(), requestId, blobType, blobContentType, blobContentEncoding, blobContentLanguage, blobContentMD5Converted, blobCacheControl, blobContentDisposition, leaseId, encryptionScope, ifModifiedSinceConverted, ifUnmodifiedSinceConverted, ifMatch, ifNoneMatch, context);
}
/**
@@ -126,19 +130,21 @@ public Mono createWithRestResponseAsync(String contai
* @param contentLength The length of the request.
* @param timeout The timeout parameter is expressed in seconds. For more information, see <a href="https://docs.microsoft.com/en-us/rest/api/storageservices/fileservices/setting-timeouts-for-blob-service-operations">Setting Timeouts for Blob Service Operations.</a>.
* @param metadata Optional. Specifies a user-defined name-value pair associated with the blob. If no name-value pairs are specified, the operation will copy the metadata from the source blob or file to the destination blob. If one or more name-value pairs are specified, the destination blob is created with the specified metadata, and metadata is not copied from the source blob or file. Note that beginning with version 2009-09-19, metadata names must adhere to the naming rules for C# identifiers. See Naming and Referencing Containers, Blobs, and Metadata for more information.
- * @param encryptionKey Optional. Specifies the encryption key to use to encrypt the data provided in the request. If not specified, encryption is performed with the root account encryption key. For more information, see Encryption at Rest for Azure Storage Services.
- * @param encryptionKeySha256 The SHA-256 hash of the provided encryption key. Must be provided if the x-ms-encryption-key header is provided.
- * @param encryptionAlgorithm The algorithm used to produce the encryption key hash. Currently, the only accepted value is "AES256". Must be provided if the x-ms-encryption-key header is provided. Possible values include: 'AES256'.
+ * @param tags Optional. A URL encoded query param string which specifies the tags to be created with the Blob object. e.g. TagName1=TagValue1&TagName2=TagValue2. The x-ms-tags header may contain up to 2kb of tags.
+ * @param xMsEncryptionKey Optional. Specifies the encryption key to use to encrypt the data provided in the request. If not specified, encryption is performed with the root account encryption key. For more information, see Encryption at Rest for Azure Storage Services.
+ * @param xMsEncryptionKeySha256 The SHA-256 hash of the provided encryption key. Must be provided if the x-ms-encryption-key header is provided.
+ * @param xMsEncryptionAlgorithm The algorithm used to produce the encryption key hash. Currently, the only accepted value is "AES256". Must be provided if the x-ms-encryption-key header is provided. Possible values include: 'AES256'.
* @param requestId Provides a client-generated, opaque value with a 1 KB character limit that is recorded in the analytics logs when storage analytics logging is enabled.
* @param blobHTTPHeaders Additional parameters for the operation.
* @param leaseAccessConditions Additional parameters for the operation.
+ * @param customerProvidedKeyInfo Additional parameters for the operation.
* @param modifiedAccessConditions Additional parameters for the operation.
* @param context The context to associate with this operation.
* @throws IllegalArgumentException thrown if parameters fail the validation.
* @return a Mono which performs the network request upon subscription.
*/
@ServiceMethod(returns = ReturnType.SINGLE)
- public Mono createWithRestResponseAsync(String containerName, String blob, long contentLength, Integer timeout, Map metadata, String encryptionKey, String encryptionKeySha256, EncryptionAlgorithmType encryptionAlgorithm, String requestId, BlobHTTPHeaders blobHTTPHeaders, LeaseAccessConditions leaseAccessConditions, ModifiedAccessConditions modifiedAccessConditions, Context context) {
+ public Mono createWithRestResponseAsync(String containerName, String blob, long contentLength, Integer timeout, Map metadata, String tags, String xMsEncryptionKey, String xMsEncryptionKeySha256, EncryptionAlgorithmType xMsEncryptionAlgorithm, String requestId, BlobHTTPHeaders blobHTTPHeaders, LeaseAccessConditions leaseAccessConditions, CustomerProvidedKeyInfo customerProvidedKeyInfo, ModifiedAccessConditions modifiedAccessConditions, Context context) {
final String blobType = "AppendBlob";
String blobContentType = null;
if (blobHTTPHeaders != null) {
@@ -168,6 +174,10 @@ public Mono createWithRestResponseAsync(String contai
if (leaseAccessConditions != null) {
leaseId = leaseAccessConditions.leaseId();
}
+ String encryptionScope = null;
+ if (customerProvidedKeyInfo != null) {
+ encryptionScope = customerProvidedKeyInfo.encryptionScope();
+ }
OffsetDateTime ifModifiedSince = null;
if (modifiedAccessConditions != null) {
ifModifiedSince = modifiedAccessConditions.ifModifiedSince();
@@ -187,7 +197,7 @@ public Mono createWithRestResponseAsync(String contai
String blobContentMD5Converted = Base64Util.encodeToString(blobContentMD5);
DateTimeRfc1123 ifModifiedSinceConverted = ifModifiedSince == null ? null : new DateTimeRfc1123(ifModifiedSince);
DateTimeRfc1123 ifUnmodifiedSinceConverted = ifUnmodifiedSince == null ? null : new DateTimeRfc1123(ifUnmodifiedSince);
- return service.create(containerName, blob, this.client.getUrl(), timeout, contentLength, metadata, encryptionKey, encryptionKeySha256, encryptionAlgorithm, this.client.getVersion(), requestId, blobType, blobContentType, blobContentEncoding, blobContentLanguage, blobContentMD5Converted, blobCacheControl, blobContentDisposition, leaseId, ifModifiedSinceConverted, ifUnmodifiedSinceConverted, ifMatch, ifNoneMatch, context);
+ return service.create(containerName, blob, this.client.getUrl(), timeout, contentLength, metadata, tags, xMsEncryptionKey, xMsEncryptionKeySha256, xMsEncryptionAlgorithm, this.client.getVersion(), requestId, blobType, blobContentType, blobContentEncoding, blobContentLanguage, blobContentMD5Converted, blobCacheControl, blobContentDisposition, leaseId, encryptionScope, ifModifiedSinceConverted, ifUnmodifiedSinceConverted, ifMatch, ifNoneMatch, context);
}
/**
@@ -204,20 +214,22 @@ public Mono createWithRestResponseAsync(String contai
@ServiceMethod(returns = ReturnType.SINGLE)
public Mono appendBlockWithRestResponseAsync(String containerName, String blob, Flux body, long contentLength, Context context) {
final Integer timeout = null;
- final String encryptionKey = null;
- final String encryptionKeySha256 = null;
- final EncryptionAlgorithmType encryptionAlgorithm = null;
+ final String xMsEncryptionKey = null;
+ final String xMsEncryptionKeySha256 = null;
+ final EncryptionAlgorithmType xMsEncryptionAlgorithm = null;
final String requestId = null;
final String comp = "appendblock";
final String leaseId = null;
final Long maxSize = null;
final Long appendPosition = null;
+ final String encryptionScope = null;
final String ifMatch = null;
final String ifNoneMatch = null;
String transactionalContentMD5Converted = null;
+ String transactionalContentCrc64Converted = null;
DateTimeRfc1123 ifModifiedSinceConverted = null;
DateTimeRfc1123 ifUnmodifiedSinceConverted = null;
- return service.appendBlock(containerName, blob, this.client.getUrl(), body, timeout, contentLength, transactionalContentMD5Converted, encryptionKey, encryptionKeySha256, encryptionAlgorithm, this.client.getVersion(), requestId, comp, leaseId, maxSize, appendPosition, ifModifiedSinceConverted, ifUnmodifiedSinceConverted, ifMatch, ifNoneMatch, context);
+ return service.appendBlock(containerName, blob, this.client.getUrl(), body, timeout, contentLength, transactionalContentMD5Converted, transactionalContentCrc64Converted, xMsEncryptionKey, xMsEncryptionKeySha256, xMsEncryptionAlgorithm, this.client.getVersion(), requestId, comp, leaseId, maxSize, appendPosition, encryptionScope, ifModifiedSinceConverted, ifUnmodifiedSinceConverted, ifMatch, ifNoneMatch, context);
}
/**
@@ -229,19 +241,21 @@ public Mono appendBlockWithRestResponseAsync(Str
* @param contentLength The length of the request.
* @param timeout The timeout parameter is expressed in seconds. For more information, see <a href="https://docs.microsoft.com/en-us/rest/api/storageservices/fileservices/setting-timeouts-for-blob-service-operations">Setting Timeouts for Blob Service Operations.</a>.
* @param transactionalContentMD5 Specify the transactional md5 for the body, to be validated by the service.
- * @param encryptionKey Optional. Specifies the encryption key to use to encrypt the data provided in the request. If not specified, encryption is performed with the root account encryption key. For more information, see Encryption at Rest for Azure Storage Services.
- * @param encryptionKeySha256 The SHA-256 hash of the provided encryption key. Must be provided if the x-ms-encryption-key header is provided.
- * @param encryptionAlgorithm The algorithm used to produce the encryption key hash. Currently, the only accepted value is "AES256". Must be provided if the x-ms-encryption-key header is provided. Possible values include: 'AES256'.
+ * @param transactionalContentCrc64 Specify the transactional crc64 for the body, to be validated by the service.
+ * @param xMsEncryptionKey Optional. Specifies the encryption key to use to encrypt the data provided in the request. If not specified, encryption is performed with the root account encryption key. For more information, see Encryption at Rest for Azure Storage Services.
+ * @param xMsEncryptionKeySha256 The SHA-256 hash of the provided encryption key. Must be provided if the x-ms-encryption-key header is provided.
+ * @param xMsEncryptionAlgorithm The algorithm used to produce the encryption key hash. Currently, the only accepted value is "AES256". Must be provided if the x-ms-encryption-key header is provided. Possible values include: 'AES256'.
* @param requestId Provides a client-generated, opaque value with a 1 KB character limit that is recorded in the analytics logs when storage analytics logging is enabled.
* @param leaseAccessConditions Additional parameters for the operation.
* @param appendPositionAccessConditions Additional parameters for the operation.
+ * @param customerProvidedKeyInfo Additional parameters for the operation.
* @param modifiedAccessConditions Additional parameters for the operation.
* @param context The context to associate with this operation.
* @throws IllegalArgumentException thrown if parameters fail the validation.
* @return a Mono which performs the network request upon subscription.
*/
@ServiceMethod(returns = ReturnType.SINGLE)
- public Mono appendBlockWithRestResponseAsync(String containerName, String blob, Flux body, long contentLength, Integer timeout, byte[] transactionalContentMD5, String encryptionKey, String encryptionKeySha256, EncryptionAlgorithmType encryptionAlgorithm, String requestId, LeaseAccessConditions leaseAccessConditions, AppendPositionAccessConditions appendPositionAccessConditions, ModifiedAccessConditions modifiedAccessConditions, Context context) {
+ public Mono appendBlockWithRestResponseAsync(String containerName, String blob, Flux body, long contentLength, Integer timeout, byte[] transactionalContentMD5, byte[] transactionalContentCrc64, String xMsEncryptionKey, String xMsEncryptionKeySha256, EncryptionAlgorithmType xMsEncryptionAlgorithm, String requestId, LeaseAccessConditions leaseAccessConditions, AppendPositionAccessConditions appendPositionAccessConditions, CustomerProvidedKeyInfo customerProvidedKeyInfo, ModifiedAccessConditions modifiedAccessConditions, Context context) {
final String comp = "appendblock";
String leaseId = null;
if (leaseAccessConditions != null) {
@@ -255,6 +269,10 @@ public Mono appendBlockWithRestResponseAsync(Str
if (appendPositionAccessConditions != null) {
appendPosition = appendPositionAccessConditions.appendPosition();
}
+ String encryptionScope = null;
+ if (customerProvidedKeyInfo != null) {
+ encryptionScope = customerProvidedKeyInfo.encryptionScope();
+ }
OffsetDateTime ifModifiedSince = null;
if (modifiedAccessConditions != null) {
ifModifiedSince = modifiedAccessConditions.ifModifiedSince();
@@ -272,9 +290,10 @@ public Mono appendBlockWithRestResponseAsync(Str
ifNoneMatch = modifiedAccessConditions.ifNoneMatch();
}
String transactionalContentMD5Converted = Base64Util.encodeToString(transactionalContentMD5);
+ String transactionalContentCrc64Converted = Base64Util.encodeToString(transactionalContentCrc64);
DateTimeRfc1123 ifModifiedSinceConverted = ifModifiedSince == null ? null : new DateTimeRfc1123(ifModifiedSince);
DateTimeRfc1123 ifUnmodifiedSinceConverted = ifUnmodifiedSince == null ? null : new DateTimeRfc1123(ifUnmodifiedSince);
- return service.appendBlock(containerName, blob, this.client.getUrl(), body, timeout, contentLength, transactionalContentMD5Converted, encryptionKey, encryptionKeySha256, encryptionAlgorithm, this.client.getVersion(), requestId, comp, leaseId, maxSize, appendPosition, ifModifiedSinceConverted, ifUnmodifiedSinceConverted, ifMatch, ifNoneMatch, context);
+ return service.appendBlock(containerName, blob, this.client.getUrl(), body, timeout, contentLength, transactionalContentMD5Converted, transactionalContentCrc64Converted, xMsEncryptionKey, xMsEncryptionKeySha256, xMsEncryptionAlgorithm, this.client.getVersion(), requestId, comp, leaseId, maxSize, appendPosition, encryptionScope, ifModifiedSinceConverted, ifUnmodifiedSinceConverted, ifMatch, ifNoneMatch, context);
}
/**
@@ -302,11 +321,13 @@ public Mono appendBlockFromUrlWithRestRes
final String sourceIfMatch = null;
final String sourceIfNoneMatch = null;
String sourceContentMD5Converted = null;
+ String sourceContentcrc64Converted = null;
+ String transactionalContentMD5Converted = null;
DateTimeRfc1123 ifModifiedSinceConverted = null;
DateTimeRfc1123 ifUnmodifiedSinceConverted = null;
DateTimeRfc1123 sourceIfModifiedSinceConverted = null;
DateTimeRfc1123 sourceIfUnmodifiedSinceConverted = null;
- return service.appendBlockFromUrl(containerName, blob, this.client.getUrl(), sourceUrl, sourceRange, sourceContentMD5Converted, timeout, contentLength, this.client.getVersion(), requestId, comp, leaseId, maxSize, appendPosition, ifModifiedSinceConverted, ifUnmodifiedSinceConverted, ifMatch, ifNoneMatch, sourceIfModifiedSinceConverted, sourceIfUnmodifiedSinceConverted, sourceIfMatch, sourceIfNoneMatch, context);
+ return service.appendBlockFromUrl(containerName, blob, this.client.getUrl(), sourceUrl, sourceRange, sourceContentMD5Converted, sourceContentcrc64Converted, timeout, contentLength, transactionalContentMD5Converted, this.client.getVersion(), requestId, comp, leaseId, maxSize, appendPosition, ifModifiedSinceConverted, ifUnmodifiedSinceConverted, ifMatch, ifNoneMatch, sourceIfModifiedSinceConverted, sourceIfUnmodifiedSinceConverted, sourceIfMatch, sourceIfNoneMatch, context);
}
/**
@@ -318,7 +339,9 @@ public Mono appendBlockFromUrlWithRestRes
* @param contentLength The length of the request.
* @param sourceRange Bytes of source data in the specified range.
* @param sourceContentMD5 Specify the md5 calculated for the range of bytes that must be read from the copy source.
+ * @param sourceContentcrc64 Specify the crc64 calculated for the range of bytes that must be read from the copy source.
* @param timeout The timeout parameter is expressed in seconds. For more information, see <a href="https://docs.microsoft.com/en-us/rest/api/storageservices/fileservices/setting-timeouts-for-blob-service-operations">Setting Timeouts for Blob Service Operations.</a>.
+ * @param transactionalContentMD5 Specify the transactional md5 for the body, to be validated by the service.
* @param requestId Provides a client-generated, opaque value with a 1 KB character limit that is recorded in the analytics logs when storage analytics logging is enabled.
* @param leaseAccessConditions Additional parameters for the operation.
* @param appendPositionAccessConditions Additional parameters for the operation.
@@ -329,7 +352,7 @@ public Mono appendBlockFromUrlWithRestRes
* @return a Mono which performs the network request upon subscription.
*/
@ServiceMethod(returns = ReturnType.SINGLE)
- public Mono appendBlockFromUrlWithRestResponseAsync(String containerName, String blob, URL sourceUrl, long contentLength, String sourceRange, byte[] sourceContentMD5, Integer timeout, String requestId, LeaseAccessConditions leaseAccessConditions, AppendPositionAccessConditions appendPositionAccessConditions, ModifiedAccessConditions modifiedAccessConditions, SourceModifiedAccessConditions sourceModifiedAccessConditions, Context context) {
+ public Mono appendBlockFromUrlWithRestResponseAsync(String containerName, String blob, URL sourceUrl, long contentLength, String sourceRange, byte[] sourceContentMD5, byte[] sourceContentcrc64, Integer timeout, byte[] transactionalContentMD5, String requestId, LeaseAccessConditions leaseAccessConditions, AppendPositionAccessConditions appendPositionAccessConditions, ModifiedAccessConditions modifiedAccessConditions, SourceModifiedAccessConditions sourceModifiedAccessConditions, Context context) {
final String comp = "appendblock";
String leaseId = null;
if (leaseAccessConditions != null) {
@@ -376,10 +399,12 @@ public Mono appendBlockFromUrlWithRestRes
sourceIfNoneMatch = sourceModifiedAccessConditions.sourceIfNoneMatch();
}
String sourceContentMD5Converted = Base64Util.encodeToString(sourceContentMD5);
+ String sourceContentcrc64Converted = Base64Util.encodeToString(sourceContentcrc64);
+ String transactionalContentMD5Converted = Base64Util.encodeToString(transactionalContentMD5);
DateTimeRfc1123 ifModifiedSinceConverted = ifModifiedSince == null ? null : new DateTimeRfc1123(ifModifiedSince);
DateTimeRfc1123 ifUnmodifiedSinceConverted = ifUnmodifiedSince == null ? null : new DateTimeRfc1123(ifUnmodifiedSince);
DateTimeRfc1123 sourceIfModifiedSinceConverted = sourceIfModifiedSince == null ? null : new DateTimeRfc1123(sourceIfModifiedSince);
DateTimeRfc1123 sourceIfUnmodifiedSinceConverted = sourceIfUnmodifiedSince == null ? null : new DateTimeRfc1123(sourceIfUnmodifiedSince);
- return service.appendBlockFromUrl(containerName, blob, this.client.getUrl(), sourceUrl, sourceRange, sourceContentMD5Converted, timeout, contentLength, this.client.getVersion(), requestId, comp, leaseId, maxSize, appendPosition, ifModifiedSinceConverted, ifUnmodifiedSinceConverted, ifMatch, ifNoneMatch, sourceIfModifiedSinceConverted, sourceIfUnmodifiedSinceConverted, sourceIfMatch, sourceIfNoneMatch, context);
+ return service.appendBlockFromUrl(containerName, blob, this.client.getUrl(), sourceUrl, sourceRange, sourceContentMD5Converted, sourceContentcrc64Converted, timeout, contentLength, transactionalContentMD5Converted, this.client.getVersion(), requestId, comp, leaseId, maxSize, appendPosition, ifModifiedSinceConverted, ifUnmodifiedSinceConverted, ifMatch, ifNoneMatch, sourceIfModifiedSinceConverted, sourceIfUnmodifiedSinceConverted, sourceIfMatch, sourceIfNoneMatch, context);
}
}
diff --git a/sdk/storage/azure-storage-blob/src/main/java/com/azure/storage/blob/implementation/AzureBlobStorageBuilder.java b/sdk/storage/azure-storage-blob/src/main/java/com/azure/storage/blob/implementation/AzureBlobStorageBuilder.java
index fa28f6e26d0ed..fe79309a238bf 100644
--- a/sdk/storage/azure-storage-blob/src/main/java/com/azure/storage/blob/implementation/AzureBlobStorageBuilder.java
+++ b/sdk/storage/azure-storage-blob/src/main/java/com/azure/storage/blob/implementation/AzureBlobStorageBuilder.java
@@ -7,6 +7,7 @@
import com.azure.core.http.HttpPipeline;
import com.azure.core.implementation.RestProxy;
import com.azure.core.implementation.annotation.ServiceClientBuilder;
+import com.azure.storage.blob.models.PathRenameMode;
/**
* A builder for creating a new instance of the AzureBlobStorage type.
@@ -45,6 +46,38 @@ public AzureBlobStorageBuilder version(String version) {
return this;
}
+ /*
+ * The filter parameter enables the caller to query blobs whose tags match a given expression. The given expression must evaluate to true for a blob to be returned in the results.
+ */
+ private String filter;
+
+ /**
+ * Sets The filter parameter enables the caller to query blobs whose tags match a given expression. The given expression must evaluate to true for a blob to be returned in the results.
+ *
+ * @param filter the filter value.
+ * @return the AzureBlobStorageBuilder.
+ */
+ public AzureBlobStorageBuilder filter(String filter) {
+ this.filter = filter;
+ return this;
+ }
+
+ /*
+ * Determines the behavior of the rename operation. Possible values include: 'legacy', 'posix'
+ */
+ private PathRenameMode pathRenameMode;
+
+ /**
+ * Sets Determines the behavior of the rename operation. Possible values include: 'legacy', 'posix'.
+ *
+ * @param pathRenameMode the pathRenameMode value.
+ * @return the AzureBlobStorageBuilder.
+ */
+ public AzureBlobStorageBuilder pathRenameMode(PathRenameMode pathRenameMode) {
+ this.pathRenameMode = pathRenameMode;
+ return this;
+ }
+
/*
* The HTTP pipeline to send requests through
*/
@@ -67,6 +100,9 @@ public AzureBlobStorageBuilder pipeline(HttpPipeline pipeline) {
* @return an instance of AzureBlobStorageImpl.
*/
public AzureBlobStorageImpl build() {
+ if (version == null) {
+ this.version = "2019-02-02";
+ }
if (pipeline == null) {
this.pipeline = RestProxy.createDefaultPipeline();
}
@@ -76,8 +112,12 @@ public AzureBlobStorageImpl build() {
}
if (this.version != null) {
client.setVersion(this.version);
- } else {
- client.setVersion("2018-11-09");
+ }
+ if (this.filter != null) {
+ client.setFilter(this.filter);
+ }
+ if (this.pathRenameMode != null) {
+ client.setPathRenameMode(this.pathRenameMode);
}
return client;
}
diff --git a/sdk/storage/azure-storage-blob/src/main/java/com/azure/storage/blob/implementation/AzureBlobStorageImpl.java b/sdk/storage/azure-storage-blob/src/main/java/com/azure/storage/blob/implementation/AzureBlobStorageImpl.java
index 5fc9bc8ae2736..d9f48fbf87990 100644
--- a/sdk/storage/azure-storage-blob/src/main/java/com/azure/storage/blob/implementation/AzureBlobStorageImpl.java
+++ b/sdk/storage/azure-storage-blob/src/main/java/com/azure/storage/blob/implementation/AzureBlobStorageImpl.java
@@ -6,6 +6,7 @@
import com.azure.core.http.HttpPipeline;
import com.azure.core.implementation.RestProxy;
+import com.azure.storage.blob.models.PathRenameMode;
/**
* Initializes a new instance of the AzureBlobStorage type.
@@ -29,9 +30,11 @@ public String getUrl() {
* Sets The URL of the service account, container, or blob that is the targe of the desired operation.
*
* @param url the url value.
+ * @return the service client itself.
*/
- void setUrl(String url) {
+ AzureBlobStorageImpl setUrl(String url) {
this.url = url;
+ return this;
}
/**
@@ -52,9 +55,61 @@ public String getVersion() {
* Sets Specifies the version of the operation to use for this request.
*
* @param version the version value.
+ * @return the service client itself.
*/
- void setVersion(String version) {
+ AzureBlobStorageImpl setVersion(String version) {
this.version = version;
+ return this;
+ }
+
+ /**
+ * The filter parameter enables the caller to query blobs whose tags match a given expression. The given expression must evaluate to true for a blob to be returned in the results.
+ */
+ private String filter;
+
+ /**
+ * Gets The filter parameter enables the caller to query blobs whose tags match a given expression. The given expression must evaluate to true for a blob to be returned in the results.
+ *
+ * @return the filter value.
+ */
+ public String getFilter() {
+ return this.filter;
+ }
+
+ /**
+ * Sets The filter parameter enables the caller to query blobs whose tags match a given expression. The given expression must evaluate to true for a blob to be returned in the results.
+ *
+ * @param filter the filter value.
+ * @return the service client itself.
+ */
+ AzureBlobStorageImpl setFilter(String filter) {
+ this.filter = filter;
+ return this;
+ }
+
+ /**
+ * Determines the behavior of the rename operation. Possible values include: 'legacy', 'posix'.
+ */
+ private PathRenameMode pathRenameMode;
+
+ /**
+ * Gets Determines the behavior of the rename operation. Possible values include: 'legacy', 'posix'.
+ *
+ * @return the pathRenameMode value.
+ */
+ public PathRenameMode getPathRenameMode() {
+ return this.pathRenameMode;
+ }
+
+ /**
+ * Sets Determines the behavior of the rename operation. Possible values include: 'legacy', 'posix'.
+ *
+ * @param pathRenameMode the pathRenameMode value.
+ * @return the service client itself.
+ */
+ AzureBlobStorageImpl setPathRenameMode(PathRenameMode pathRenameMode) {
+ this.pathRenameMode = pathRenameMode;
+ return this;
}
/**
@@ -99,6 +154,20 @@ public ContainersImpl containers() {
return this.containers;
}
+ /**
+ * The DirectorysImpl object to access its operations.
+ */
+ private DirectorysImpl directorys;
+
+ /**
+ * Gets the DirectorysImpl object to access its operations.
+ *
+ * @return the DirectorysImpl object.
+ */
+ public DirectorysImpl directorys() {
+ return this.directorys;
+ }
+
/**
* The BlobsImpl object to access its operations.
*/
@@ -171,6 +240,7 @@ public AzureBlobStorageImpl(HttpPipeline httpPipeline) {
this.httpPipeline = httpPipeline;
this.services = new ServicesImpl(this);
this.containers = new ContainersImpl(this);
+ this.directorys = new DirectorysImpl(this);
this.blobs = new BlobsImpl(this);
this.pageBlobs = new PageBlobsImpl(this);
this.appendBlobs = new AppendBlobsImpl(this);
diff --git a/sdk/storage/azure-storage-blob/src/main/java/com/azure/storage/blob/implementation/BlobsImpl.java b/sdk/storage/azure-storage-blob/src/main/java/com/azure/storage/blob/implementation/BlobsImpl.java
index eba1efa297e4b..9f75f3503418a 100644
--- a/sdk/storage/azure-storage-blob/src/main/java/com/azure/storage/blob/implementation/BlobsImpl.java
+++ b/sdk/storage/azure-storage-blob/src/main/java/com/azure/storage/blob/implementation/BlobsImpl.java
@@ -6,6 +6,7 @@
import com.azure.core.implementation.DateTimeRfc1123;
import com.azure.core.implementation.RestProxy;
+import com.azure.core.implementation.annotation.BodyParam;
import com.azure.core.implementation.annotation.Delete;
import com.azure.core.implementation.annotation.ExpectedResponses;
import com.azure.core.implementation.annotation.Get;
@@ -22,7 +23,8 @@
import com.azure.core.implementation.annotation.UnexpectedResponseExceptionType;
import com.azure.core.implementation.util.Base64Util;
import com.azure.core.util.Context;
-import com.azure.storage.blob.models.AccessTier;
+import com.azure.storage.blob.models.AccessTierOptional;
+import com.azure.storage.blob.models.AccessTierRequired;
import com.azure.storage.blob.models.BlobHTTPHeaders;
import com.azure.storage.blob.models.BlobsAbortCopyFromURLResponse;
import com.azure.storage.blob.models.BlobsAcquireLeaseResponse;
@@ -34,17 +36,26 @@
import com.azure.storage.blob.models.BlobsDownloadResponse;
import com.azure.storage.blob.models.BlobsGetAccountInfoResponse;
import com.azure.storage.blob.models.BlobsGetPropertiesResponse;
+import com.azure.storage.blob.models.BlobsGetTagsResponse;
import com.azure.storage.blob.models.BlobsReleaseLeaseResponse;
+import com.azure.storage.blob.models.BlobsRenameResponse;
import com.azure.storage.blob.models.BlobsRenewLeaseResponse;
import com.azure.storage.blob.models.BlobsSetHTTPHeadersResponse;
import com.azure.storage.blob.models.BlobsSetMetadataResponse;
+import com.azure.storage.blob.models.BlobsSetTagsResponse;
import com.azure.storage.blob.models.BlobsSetTierResponse;
import com.azure.storage.blob.models.BlobsStartCopyFromURLResponse;
import com.azure.storage.blob.models.BlobsUndeleteResponse;
+import com.azure.storage.blob.models.BlobTags;
+import com.azure.storage.blob.models.CustomerProvidedKeyInfo;
+import com.azure.storage.blob.models.DataLakeStorageErrorException;
import com.azure.storage.blob.models.DeleteSnapshotsOptionType;
+import com.azure.storage.blob.models.DirectoryHttpHeaders;
import com.azure.storage.blob.models.EncryptionAlgorithmType;
import com.azure.storage.blob.models.LeaseAccessConditions;
import com.azure.storage.blob.models.ModifiedAccessConditions;
+import com.azure.storage.blob.models.PathRenameMode;
+import com.azure.storage.blob.models.RehydratePriority;
import com.azure.storage.blob.models.SourceModifiedAccessConditions;
import com.azure.storage.blob.models.StorageErrorException;
import java.net.URL;
@@ -87,18 +98,23 @@ private interface BlobsService {
@Get("{containerName}/{blob}")
@ExpectedResponses({200, 206})
@UnexpectedResponseExceptionType(StorageErrorException.class)
- Mono download(@PathParam("containerName") String containerName, @PathParam("blob") String blob, @HostParam("url") String url, @QueryParam("snapshot") String snapshot, @QueryParam("versionid") String versionId, @QueryParam("timeout") Integer timeout, @HeaderParam("x-ms-range") String range, @HeaderParam("x-ms-range-get-content-md5") Boolean rangeGetContentMD5, @QueryParam("x-ms-encryption-key") String encryptionKey, @QueryParam("x-ms-encryption-key-sha256") String encryptionKeySha256, @QueryParam("x-ms-encryption-algorithm") EncryptionAlgorithmType encryptionAlgorithm, @HeaderParam("x-ms-version") String version, @HeaderParam("x-ms-client-request-id") String requestId, @HeaderParam("x-ms-lease-id") String leaseId, @HeaderParam("If-Modified-Since") DateTimeRfc1123 ifModifiedSince, @HeaderParam("If-Unmodified-Since") DateTimeRfc1123 ifUnmodifiedSince, @HeaderParam("If-Match") String ifMatch, @HeaderParam("If-None-Match") String ifNoneMatch, Context context);
+ Mono download(@PathParam("containerName") String containerName, @PathParam("blob") String blob, @HostParam("url") String url, @QueryParam("snapshot") String snapshot, @QueryParam("versionid") String versionId, @QueryParam("timeout") Integer timeout, @HeaderParam("x-ms-range") String range, @HeaderParam("x-ms-range-get-content-md5") Boolean rangeGetContentMD5, @HeaderParam("x-ms-range-get-content-crc64") Boolean rangeGetContentCRC64, @QueryParam("x-ms-encryption-key") String xMsEncryptionKey, @QueryParam("x-ms-encryption-key-sha256") String xMsEncryptionKeySha256, @QueryParam("x-ms-encryption-algorithm") EncryptionAlgorithmType xMsEncryptionAlgorithm, @HeaderParam("x-ms-version") String version, @HeaderParam("x-ms-client-request-id") String requestId, @HeaderParam("x-ms-lease-id") String leaseId, @HeaderParam("If-Modified-Since") DateTimeRfc1123 ifModifiedSince, @HeaderParam("If-Unmodified-Since") DateTimeRfc1123 ifUnmodifiedSince, @HeaderParam("If-Match") String ifMatch, @HeaderParam("If-None-Match") String ifNoneMatch, Context context);
@Head("{containerName}/{blob}")
@ExpectedResponses({200})
@UnexpectedResponseExceptionType(StorageErrorException.class)
- Mono getProperties(@PathParam("containerName") String containerName, @PathParam("blob") String blob, @HostParam("url") String url, @QueryParam("snapshot") String snapshot, @QueryParam("versionid") String versionId, @QueryParam("timeout") Integer timeout, @QueryParam("x-ms-encryption-key") String encryptionKey, @QueryParam("x-ms-encryption-key-sha256") String encryptionKeySha256, @QueryParam("x-ms-encryption-algorithm") EncryptionAlgorithmType encryptionAlgorithm, @HeaderParam("x-ms-version") String version, @HeaderParam("x-ms-client-request-id") String requestId, @HeaderParam("x-ms-lease-id") String leaseId, @HeaderParam("If-Modified-Since") DateTimeRfc1123 ifModifiedSince, @HeaderParam("If-Unmodified-Since") DateTimeRfc1123 ifUnmodifiedSince, @HeaderParam("If-Match") String ifMatch, @HeaderParam("If-None-Match") String ifNoneMatch, Context context);
+ Mono getProperties(@PathParam("containerName") String containerName, @PathParam("blob") String blob, @HostParam("url") String url, @QueryParam("snapshot") String snapshot, @QueryParam("versionid") String versionId, @QueryParam("timeout") Integer timeout, @QueryParam("x-ms-encryption-key") String xMsEncryptionKey, @QueryParam("x-ms-encryption-key-sha256") String xMsEncryptionKeySha256, @QueryParam("x-ms-encryption-algorithm") EncryptionAlgorithmType xMsEncryptionAlgorithm, @HeaderParam("x-ms-version") String version, @HeaderParam("x-ms-client-request-id") String requestId, @HeaderParam("x-ms-lease-id") String leaseId, @HeaderParam("If-Modified-Since") DateTimeRfc1123 ifModifiedSince, @HeaderParam("If-Unmodified-Since") DateTimeRfc1123 ifUnmodifiedSince, @HeaderParam("If-Match") String ifMatch, @HeaderParam("If-None-Match") String ifNoneMatch, Context context);
@Delete("{containerName}/{blob}")
@ExpectedResponses({202})
@UnexpectedResponseExceptionType(StorageErrorException.class)
Mono delete(@PathParam("containerName") String containerName, @PathParam("blob") String blob, @HostParam("url") String url, @QueryParam("snapshot") String snapshot, @QueryParam("versionid") String versionId, @QueryParam("timeout") Integer timeout, @HeaderParam("x-ms-delete-snapshots") DeleteSnapshotsOptionType deleteSnapshots, @HeaderParam("x-ms-version") String version, @HeaderParam("x-ms-client-request-id") String requestId, @HeaderParam("x-ms-lease-id") String leaseId, @HeaderParam("If-Modified-Since") DateTimeRfc1123 ifModifiedSince, @HeaderParam("If-Unmodified-Since") DateTimeRfc1123 ifUnmodifiedSince, @HeaderParam("If-Match") String ifMatch, @HeaderParam("If-None-Match") String ifNoneMatch, Context context);
+ @Put("{filesystem}/{path}")
+ @ExpectedResponses({201})
+ @UnexpectedResponseExceptionType(DataLakeStorageErrorException.class)
+ Mono rename(@PathParam("filesystem") String filesystem, @PathParam("path") String path, @HostParam("url") String url, @QueryParam("timeout") Integer timeout, @QueryParam("mode") PathRenameMode pathRenameMode, @HeaderParam("x-ms-rename-source") String renameSource, @HeaderParam("x-ms-properties") String directoryProperties, @HeaderParam("x-ms-permissions") String posixPermissions, @HeaderParam("x-ms-umask") String posixUmask, @HeaderParam("x-ms-source-lease-id") String sourceLeaseId, @HeaderParam("x-ms-version") String version, @HeaderParam("x-ms-client-request-id") String requestId, @HeaderParam("x-ms-cache-control") String cacheControl, @HeaderParam("x-ms-content-type") String contentType, @HeaderParam("x-ms-content-encoding") String contentEncoding, @HeaderParam("x-ms-content-language") String contentLanguage, @HeaderParam("x-ms-content-disposition") String contentDisposition, @HeaderParam("x-ms-lease-id") String leaseId, @HeaderParam("If-Modified-Since") DateTimeRfc1123 ifModifiedSince, @HeaderParam("If-Unmodified-Since") DateTimeRfc1123 ifUnmodifiedSince, @HeaderParam("If-Match") String ifMatch, @HeaderParam("If-None-Match") String ifNoneMatch, @HeaderParam("x-ms-source-if-modified-since") DateTimeRfc1123 sourceIfModifiedSince, @HeaderParam("x-ms-source-if-unmodified-since") DateTimeRfc1123 sourceIfUnmodifiedSince, @HeaderParam("x-ms-source-if-match") String sourceIfMatch, @HeaderParam("x-ms-source-if-none-match") String sourceIfNoneMatch, Context context);
+
@Put("{containerName}/{blob}")
@ExpectedResponses({200})
@UnexpectedResponseExceptionType(StorageErrorException.class)
@@ -112,7 +128,7 @@ private interface BlobsService {
@Put("{containerName}/{blob}")
@ExpectedResponses({200})
@UnexpectedResponseExceptionType(StorageErrorException.class)
- Mono setMetadata(@PathParam("containerName") String containerName, @PathParam("blob") String blob, @HostParam("url") String url, @QueryParam("timeout") Integer timeout, @HeaderParam("x-ms-meta-") Map metadata, @QueryParam("x-ms-encryption-key") String encryptionKey, @QueryParam("x-ms-encryption-key-sha256") String encryptionKeySha256, @QueryParam("x-ms-encryption-algorithm") EncryptionAlgorithmType encryptionAlgorithm, @HeaderParam("x-ms-version") String version, @HeaderParam("x-ms-client-request-id") String requestId, @QueryParam("comp") String comp, @HeaderParam("x-ms-lease-id") String leaseId, @HeaderParam("If-Modified-Since") DateTimeRfc1123 ifModifiedSince, @HeaderParam("If-Unmodified-Since") DateTimeRfc1123 ifUnmodifiedSince, @HeaderParam("If-Match") String ifMatch, @HeaderParam("If-None-Match") String ifNoneMatch, Context context);
+ Mono setMetadata(@PathParam("containerName") String containerName, @PathParam("blob") String blob, @HostParam("url") String url, @QueryParam("timeout") Integer timeout, @HeaderParam("x-ms-meta-") Map metadata, @QueryParam("x-ms-encryption-key") String xMsEncryptionKey, @QueryParam("x-ms-encryption-key-sha256") String xMsEncryptionKeySha256, @QueryParam("x-ms-encryption-algorithm") EncryptionAlgorithmType xMsEncryptionAlgorithm, @HeaderParam("x-ms-version") String version, @HeaderParam("x-ms-client-request-id") String requestId, @QueryParam("comp") String comp, @HeaderParam("x-ms-lease-id") String leaseId, @QueryParam("x-ms-encryption-scope") String encryptionScope, @HeaderParam("If-Modified-Since") DateTimeRfc1123 ifModifiedSince, @HeaderParam("If-Unmodified-Since") DateTimeRfc1123 ifUnmodifiedSince, @HeaderParam("If-Match") String ifMatch, @HeaderParam("If-None-Match") String ifNoneMatch, Context context);
@Put("{containerName}/{blob}")
@ExpectedResponses({201})
@@ -142,17 +158,17 @@ private interface BlobsService {
@Put("{containerName}/{blob}")
@ExpectedResponses({201})
@UnexpectedResponseExceptionType(StorageErrorException.class)
- Mono createSnapshot(@PathParam("containerName") String containerName, @PathParam("blob") String blob, @HostParam("url") String url, @QueryParam("timeout") Integer timeout, @HeaderParam("x-ms-meta-") Map metadata, @QueryParam("x-ms-encryption-key") String encryptionKey, @QueryParam("x-ms-encryption-key-sha256") String encryptionKeySha256, @QueryParam("x-ms-encryption-algorithm") EncryptionAlgorithmType encryptionAlgorithm, @HeaderParam("x-ms-version") String version, @HeaderParam("x-ms-client-request-id") String requestId, @QueryParam("comp") String comp, @HeaderParam("If-Modified-Since") DateTimeRfc1123 ifModifiedSince, @HeaderParam("If-Unmodified-Since") DateTimeRfc1123 ifUnmodifiedSince, @HeaderParam("If-Match") String ifMatch, @HeaderParam("If-None-Match") String ifNoneMatch, @HeaderParam("x-ms-lease-id") String leaseId, Context context);
+ Mono createSnapshot(@PathParam("containerName") String containerName, @PathParam("blob") String blob, @HostParam("url") String url, @QueryParam("timeout") Integer timeout, @HeaderParam("x-ms-meta-") Map metadata, @QueryParam("x-ms-encryption-key") String xMsEncryptionKey, @QueryParam("x-ms-encryption-key-sha256") String xMsEncryptionKeySha256, @QueryParam("x-ms-encryption-algorithm") EncryptionAlgorithmType xMsEncryptionAlgorithm, @HeaderParam("x-ms-version") String version, @HeaderParam("x-ms-client-request-id") String requestId, @QueryParam("comp") String comp, @QueryParam("x-ms-encryption-scope") String encryptionScope, @HeaderParam("If-Modified-Since") DateTimeRfc1123 ifModifiedSince, @HeaderParam("If-Unmodified-Since") DateTimeRfc1123 ifUnmodifiedSince, @HeaderParam("If-Match") String ifMatch, @HeaderParam("If-None-Match") String ifNoneMatch, @HeaderParam("x-ms-lease-id") String leaseId, Context context);
@Put("{containerName}/{blob}")
@ExpectedResponses({202})
@UnexpectedResponseExceptionType(StorageErrorException.class)
- Mono startCopyFromURL(@PathParam("containerName") String containerName, @PathParam("blob") String blob, @HostParam("url") String url, @QueryParam("timeout") Integer timeout, @HeaderParam("x-ms-meta-") Map metadata, @HeaderParam("x-ms-copy-source") URL copySource, @HeaderParam("x-ms-version") String version, @HeaderParam("x-ms-client-request-id") String requestId, @HeaderParam("x-ms-source-if-modified-since") DateTimeRfc1123 sourceIfModifiedSince, @HeaderParam("x-ms-source-if-unmodified-since") DateTimeRfc1123 sourceIfUnmodifiedSince, @HeaderParam("x-ms-source-if-match") String sourceIfMatch, @HeaderParam("x-ms-source-if-none-match") String sourceIfNoneMatch, @HeaderParam("If-Modified-Since") DateTimeRfc1123 ifModifiedSince, @HeaderParam("If-Unmodified-Since") DateTimeRfc1123 ifUnmodifiedSince, @HeaderParam("If-Match") String ifMatch, @HeaderParam("If-None-Match") String ifNoneMatch, @HeaderParam("x-ms-lease-id") String leaseId, Context context);
+ Mono startCopyFromURL(@PathParam("containerName") String containerName, @PathParam("blob") String blob, @HostParam("url") String url, @QueryParam("timeout") Integer timeout, @HeaderParam("x-ms-meta-") Map metadata, @HeaderParam("x-ms-tags") String tags, @HeaderParam("x-ms-access-tier") AccessTierOptional tier, @HeaderParam("x-ms-rehydrate-priority") RehydratePriority rehydratePriority, @HeaderParam("x-ms-copy-source") URL copySource, @HeaderParam("x-ms-version") String version, @HeaderParam("x-ms-client-request-id") String requestId, @HeaderParam("x-ms-source-if-modified-since") DateTimeRfc1123 sourceIfModifiedSince, @HeaderParam("x-ms-source-if-unmodified-since") DateTimeRfc1123 sourceIfUnmodifiedSince, @HeaderParam("x-ms-source-if-match") String sourceIfMatch, @HeaderParam("x-ms-source-if-none-match") String sourceIfNoneMatch, @HeaderParam("If-Modified-Since") DateTimeRfc1123 ifModifiedSince, @HeaderParam("If-Unmodified-Since") DateTimeRfc1123 ifUnmodifiedSince, @HeaderParam("If-Match") String ifMatch, @HeaderParam("If-None-Match") String ifNoneMatch, @HeaderParam("x-ms-lease-id") String leaseId, Context context);
@Put("{containerName}/{blob}")
@ExpectedResponses({202})
@UnexpectedResponseExceptionType(StorageErrorException.class)
- Mono copyFromURL(@PathParam("containerName") String containerName, @PathParam("blob") String blob, @HostParam("url") String url, @QueryParam("timeout") Integer timeout, @HeaderParam("x-ms-meta-") Map metadata, @HeaderParam("x-ms-copy-source") URL copySource, @HeaderParam("x-ms-version") String version, @HeaderParam("x-ms-client-request-id") String requestId, @HeaderParam("x-ms-requires-sync") String xMsRequiresSync, @HeaderParam("x-ms-source-if-modified-since") DateTimeRfc1123 sourceIfModifiedSince, @HeaderParam("x-ms-source-if-unmodified-since") DateTimeRfc1123 sourceIfUnmodifiedSince, @HeaderParam("x-ms-source-if-match") String sourceIfMatch, @HeaderParam("x-ms-source-if-none-match") String sourceIfNoneMatch, @HeaderParam("If-Modified-Since") DateTimeRfc1123 ifModifiedSince, @HeaderParam("If-Unmodified-Since") DateTimeRfc1123 ifUnmodifiedSince, @HeaderParam("If-Match") String ifMatch, @HeaderParam("If-None-Match") String ifNoneMatch, @HeaderParam("x-ms-lease-id") String leaseId, Context context);
+ Mono copyFromURL(@PathParam("containerName") String containerName, @PathParam("blob") String blob, @HostParam("url") String url, @QueryParam("timeout") Integer timeout, @HeaderParam("x-ms-meta-") Map metadata, @HeaderParam("x-ms-tags") String tags, @HeaderParam("x-ms-access-tier") AccessTierOptional tier, @HeaderParam("x-ms-copy-source") URL copySource, @HeaderParam("x-ms-version") String version, @HeaderParam("x-ms-client-request-id") String requestId, @HeaderParam("x-ms-requires-sync") String xMsRequiresSync, @HeaderParam("x-ms-source-if-modified-since") DateTimeRfc1123 sourceIfModifiedSince, @HeaderParam("x-ms-source-if-unmodified-since") DateTimeRfc1123 sourceIfUnmodifiedSince, @HeaderParam("x-ms-source-if-match") String sourceIfMatch, @HeaderParam("x-ms-source-if-none-match") String sourceIfNoneMatch, @HeaderParam("If-Modified-Since") DateTimeRfc1123 ifModifiedSince, @HeaderParam("If-Unmodified-Since") DateTimeRfc1123 ifUnmodifiedSince, @HeaderParam("If-Match") String ifMatch, @HeaderParam("If-None-Match") String ifNoneMatch, @HeaderParam("x-ms-lease-id") String leaseId, Context context);
@Put("{containerName}/{blob}")
@ExpectedResponses({204})
@@ -162,16 +178,26 @@ private interface BlobsService {
@Put("{containerName}/{blob}")
@ExpectedResponses({200, 202})
@UnexpectedResponseExceptionType(StorageErrorException.class)
- Mono setTier(@PathParam("containerName") String containerName, @PathParam("blob") String blob, @HostParam("url") String url, @QueryParam("timeout") Integer timeout, @HeaderParam("x-ms-access-tier") AccessTier tier, @HeaderParam("x-ms-version") String version, @HeaderParam("x-ms-client-request-id") String requestId, @QueryParam("comp") String comp, @HeaderParam("x-ms-lease-id") String leaseId, Context context);
+ Mono setTier(@PathParam("containerName") String containerName, @PathParam("blob") String blob, @HostParam("url") String url, @QueryParam("timeout") Integer timeout, @HeaderParam("x-ms-access-tier") AccessTierRequired tier, @HeaderParam("x-ms-rehydrate-priority") RehydratePriority rehydratePriority, @HeaderParam("x-ms-version") String version, @HeaderParam("x-ms-client-request-id") String requestId, @QueryParam("comp") String comp, @HeaderParam("x-ms-lease-id") String leaseId, Context context);
@Get("{containerName}/{blob}")
@ExpectedResponses({200})
@UnexpectedResponseExceptionType(StorageErrorException.class)
Mono getAccountInfo(@PathParam("containerName") String containerName, @PathParam("blob") String blob, @HostParam("url") String url, @HeaderParam("x-ms-version") String version, @QueryParam("restype") String restype, @QueryParam("comp") String comp, Context context);
+
+ @Put("{containerName}/{blob}")
+ @ExpectedResponses({204})
+ @UnexpectedResponseExceptionType(StorageErrorException.class)
+ Mono setTags(@PathParam("containerName") String containerName, @PathParam("blob") String blob, @HostParam("url") String url, @BodyParam("application/xml; charset=utf-8") BlobTags tags, @QueryParam("timeout") Integer timeout, @HeaderParam("Content-Length") long contentLength, @HeaderParam("Content-MD5") String transactionalContentMD5, @HeaderParam("x-ms-content-crc64") String transactionalContentCrc64, @HeaderParam("x-ms-version") String version, @HeaderParam("x-ms-client-request-id") String requestId, @QueryParam("comp") String comp, Context context);
+
+ @Get("{containerName}/{blob}")
+ @ExpectedResponses({200})
+ @UnexpectedResponseExceptionType(StorageErrorException.class)
+ Mono getTags(@PathParam("containerName") String containerName, @PathParam("blob") String blob, @HostParam("url") String url, @QueryParam("timeout") Integer timeout, @HeaderParam("Content-Length") long contentLength, @QueryParam("snapshot") String snapshot, @QueryParam("versionid") String versionId, @HeaderParam("x-ms-version") String version, @HeaderParam("x-ms-client-request-id") String requestId, @QueryParam("comp") String comp, Context context);
}
/**
- * The Download operation reads or downloads a blob from the system, including its metadata and properties. You can also call Download to read a snapshot or verison.
+ * The Download operation reads or downloads a blob from the system, including its metadata and properties. You can also call Download to read a snapshot or version.
*
* @param containerName The container name.
* @param blob The blob name.
@@ -186,20 +212,21 @@ public Mono downloadWithRestResponseAsync(String containe
final Integer timeout = null;
final String range = null;
final Boolean rangeGetContentMD5 = null;
- final String encryptionKey = null;
- final String encryptionKeySha256 = null;
- final EncryptionAlgorithmType encryptionAlgorithm = null;
+ final Boolean rangeGetContentCRC64 = null;
+ final String xMsEncryptionKey = null;
+ final String xMsEncryptionKeySha256 = null;
+ final EncryptionAlgorithmType xMsEncryptionAlgorithm = null;
final String requestId = null;
final String leaseId = null;
final String ifMatch = null;
final String ifNoneMatch = null;
DateTimeRfc1123 ifModifiedSinceConverted = null;
DateTimeRfc1123 ifUnmodifiedSinceConverted = null;
- return service.download(containerName, blob, this.client.getUrl(), snapshot, versionId, timeout, range, rangeGetContentMD5, encryptionKey, encryptionKeySha256, encryptionAlgorithm, this.client.getVersion(), requestId, leaseId, ifModifiedSinceConverted, ifUnmodifiedSinceConverted, ifMatch, ifNoneMatch, context);
+ return service.download(containerName, blob, this.client.getUrl(), snapshot, versionId, timeout, range, rangeGetContentMD5, rangeGetContentCRC64, xMsEncryptionKey, xMsEncryptionKeySha256, xMsEncryptionAlgorithm, this.client.getVersion(), requestId, leaseId, ifModifiedSinceConverted, ifUnmodifiedSinceConverted, ifMatch, ifNoneMatch, context);
}
/**
- * The Download operation reads or downloads a blob from the system, including its metadata and properties. You can also call Download to read a snapshot or verison.
+ * The Download operation reads or downloads a blob from the system, including its metadata and properties. You can also call Download to read a snapshot or version.
*
* @param containerName The container name.
* @param blob The blob name.
@@ -208,9 +235,10 @@ public Mono downloadWithRestResponseAsync(String containe
* @param timeout The timeout parameter is expressed in seconds. For more information, see <a href="https://docs.microsoft.com/en-us/rest/api/storageservices/fileservices/setting-timeouts-for-blob-service-operations">Setting Timeouts for Blob Service Operations.</a>.
* @param range Return only the bytes of the blob in the specified range.
* @param rangeGetContentMD5 When set to true and specified together with the Range, the service returns the MD5 hash for the range, as long as the range is less than or equal to 4 MB in size.
- * @param encryptionKey Optional. Specifies the encryption key to use to encrypt the data provided in the request. If not specified, encryption is performed with the root account encryption key. For more information, see Encryption at Rest for Azure Storage Services.
- * @param encryptionKeySha256 The SHA-256 hash of the provided encryption key. Must be provided if the x-ms-encryption-key header is provided.
- * @param encryptionAlgorithm The algorithm used to produce the encryption key hash. Currently, the only accepted value is "AES256". Must be provided if the x-ms-encryption-key header is provided. Possible values include: 'AES256'.
+ * @param rangeGetContentCRC64 When set to true and specified together with the Range, the service returns the CRC64 hash for the range, as long as the range is less than or equal to 4 MB in size.
+ * @param xMsEncryptionKey Optional. Specifies the encryption key to use to encrypt the data provided in the request. If not specified, encryption is performed with the root account encryption key. For more information, see Encryption at Rest for Azure Storage Services.
+ * @param xMsEncryptionKeySha256 The SHA-256 hash of the provided encryption key. Must be provided if the x-ms-encryption-key header is provided.
+ * @param xMsEncryptionAlgorithm The algorithm used to produce the encryption key hash. Currently, the only accepted value is "AES256". Must be provided if the x-ms-encryption-key header is provided. Possible values include: 'AES256'.
* @param requestId Provides a client-generated, opaque value with a 1 KB character limit that is recorded in the analytics logs when storage analytics logging is enabled.
* @param leaseAccessConditions Additional parameters for the operation.
* @param modifiedAccessConditions Additional parameters for the operation.
@@ -219,7 +247,7 @@ public Mono downloadWithRestResponseAsync(String containe
* @return a Mono which performs the network request upon subscription.
*/
@ServiceMethod(returns = ReturnType.SINGLE)
- public Mono downloadWithRestResponseAsync(String containerName, String blob, String snapshot, String versionId, Integer timeout, String range, Boolean rangeGetContentMD5, String encryptionKey, String encryptionKeySha256, EncryptionAlgorithmType encryptionAlgorithm, String requestId, LeaseAccessConditions leaseAccessConditions, ModifiedAccessConditions modifiedAccessConditions, Context context) {
+ public Mono downloadWithRestResponseAsync(String containerName, String blob, String snapshot, String versionId, Integer timeout, String range, Boolean rangeGetContentMD5, Boolean rangeGetContentCRC64, String xMsEncryptionKey, String xMsEncryptionKeySha256, EncryptionAlgorithmType xMsEncryptionAlgorithm, String requestId, LeaseAccessConditions leaseAccessConditions, ModifiedAccessConditions modifiedAccessConditions, Context context) {
String leaseId = null;
if (leaseAccessConditions != null) {
leaseId = leaseAccessConditions.leaseId();
@@ -242,7 +270,7 @@ public Mono downloadWithRestResponseAsync(String containe
}
DateTimeRfc1123 ifModifiedSinceConverted = ifModifiedSince == null ? null : new DateTimeRfc1123(ifModifiedSince);
DateTimeRfc1123 ifUnmodifiedSinceConverted = ifUnmodifiedSince == null ? null : new DateTimeRfc1123(ifUnmodifiedSince);
- return service.download(containerName, blob, this.client.getUrl(), snapshot, versionId, timeout, range, rangeGetContentMD5, encryptionKey, encryptionKeySha256, encryptionAlgorithm, this.client.getVersion(), requestId, leaseId, ifModifiedSinceConverted, ifUnmodifiedSinceConverted, ifMatch, ifNoneMatch, context);
+ return service.download(containerName, blob, this.client.getUrl(), snapshot, versionId, timeout, range, rangeGetContentMD5, rangeGetContentCRC64, xMsEncryptionKey, xMsEncryptionKeySha256, xMsEncryptionAlgorithm, this.client.getVersion(), requestId, leaseId, ifModifiedSinceConverted, ifUnmodifiedSinceConverted, ifMatch, ifNoneMatch, context);
}
/**
@@ -259,16 +287,16 @@ public Mono getPropertiesWithRestResponseAsync(Strin
final String snapshot = null;
final String versionId = null;
final Integer timeout = null;
- final String encryptionKey = null;
- final String encryptionKeySha256 = null;
- final EncryptionAlgorithmType encryptionAlgorithm = null;
+ final String xMsEncryptionKey = null;
+ final String xMsEncryptionKeySha256 = null;
+ final EncryptionAlgorithmType xMsEncryptionAlgorithm = null;
final String requestId = null;
final String leaseId = null;
final String ifMatch = null;
final String ifNoneMatch = null;
DateTimeRfc1123 ifModifiedSinceConverted = null;
DateTimeRfc1123 ifUnmodifiedSinceConverted = null;
- return service.getProperties(containerName, blob, this.client.getUrl(), snapshot, versionId, timeout, encryptionKey, encryptionKeySha256, encryptionAlgorithm, this.client.getVersion(), requestId, leaseId, ifModifiedSinceConverted, ifUnmodifiedSinceConverted, ifMatch, ifNoneMatch, context);
+ return service.getProperties(containerName, blob, this.client.getUrl(), snapshot, versionId, timeout, xMsEncryptionKey, xMsEncryptionKeySha256, xMsEncryptionAlgorithm, this.client.getVersion(), requestId, leaseId, ifModifiedSinceConverted, ifUnmodifiedSinceConverted, ifMatch, ifNoneMatch, context);
}
/**
@@ -279,9 +307,9 @@ public Mono getPropertiesWithRestResponseAsync(Strin
* @param snapshot The snapshot parameter is an opaque DateTime value that, when present, specifies the blob snapshot to retrieve. For more information on working with blob snapshots, see <a href="https://docs.microsoft.com/en-us/rest/api/storageservices/fileservices/creating-a-snapshot-of-a-blob">Creating a Snapshot of a Blob.</a>.
* @param versionId The version ID parameter is an opaque DateTime value that, when present, specifies the blob version to retrieve.
* @param timeout The timeout parameter is expressed in seconds. For more information, see <a href="https://docs.microsoft.com/en-us/rest/api/storageservices/fileservices/setting-timeouts-for-blob-service-operations">Setting Timeouts for Blob Service Operations.</a>.
- * @param encryptionKey Optional. Specifies the encryption key to use to encrypt the data provided in the request. If not specified, encryption is performed with the root account encryption key. For more information, see Encryption at Rest for Azure Storage Services.
- * @param encryptionKeySha256 The SHA-256 hash of the provided encryption key. Must be provided if the x-ms-encryption-key header is provided.
- * @param encryptionAlgorithm The algorithm used to produce the encryption key hash. Currently, the only accepted value is "AES256". Must be provided if the x-ms-encryption-key header is provided. Possible values include: 'AES256'.
+ * @param xMsEncryptionKey Optional. Specifies the encryption key to use to encrypt the data provided in the request. If not specified, encryption is performed with the root account encryption key. For more information, see Encryption at Rest for Azure Storage Services.
+ * @param xMsEncryptionKeySha256 The SHA-256 hash of the provided encryption key. Must be provided if the x-ms-encryption-key header is provided.
+ * @param xMsEncryptionAlgorithm The algorithm used to produce the encryption key hash. Currently, the only accepted value is "AES256". Must be provided if the x-ms-encryption-key header is provided. Possible values include: 'AES256'.
* @param requestId Provides a client-generated, opaque value with a 1 KB character limit that is recorded in the analytics logs when storage analytics logging is enabled.
* @param leaseAccessConditions Additional parameters for the operation.
* @param modifiedAccessConditions Additional parameters for the operation.
@@ -290,7 +318,7 @@ public Mono getPropertiesWithRestResponseAsync(Strin
* @return a Mono which performs the network request upon subscription.
*/
@ServiceMethod(returns = ReturnType.SINGLE)
- public Mono getPropertiesWithRestResponseAsync(String containerName, String blob, String snapshot, String versionId, Integer timeout, String encryptionKey, String encryptionKeySha256, EncryptionAlgorithmType encryptionAlgorithm, String requestId, LeaseAccessConditions leaseAccessConditions, ModifiedAccessConditions modifiedAccessConditions, Context context) {
+ public Mono getPropertiesWithRestResponseAsync(String containerName, String blob, String snapshot, String versionId, Integer timeout, String xMsEncryptionKey, String xMsEncryptionKeySha256, EncryptionAlgorithmType xMsEncryptionAlgorithm, String requestId, LeaseAccessConditions leaseAccessConditions, ModifiedAccessConditions modifiedAccessConditions, Context context) {
String leaseId = null;
if (leaseAccessConditions != null) {
leaseId = leaseAccessConditions.leaseId();
@@ -313,7 +341,7 @@ public Mono getPropertiesWithRestResponseAsync(Strin
}
DateTimeRfc1123 ifModifiedSinceConverted = ifModifiedSince == null ? null : new DateTimeRfc1123(ifModifiedSince);
DateTimeRfc1123 ifUnmodifiedSinceConverted = ifUnmodifiedSince == null ? null : new DateTimeRfc1123(ifUnmodifiedSince);
- return service.getProperties(containerName, blob, this.client.getUrl(), snapshot, versionId, timeout, encryptionKey, encryptionKeySha256, encryptionAlgorithm, this.client.getVersion(), requestId, leaseId, ifModifiedSinceConverted, ifUnmodifiedSinceConverted, ifMatch, ifNoneMatch, context);
+ return service.getProperties(containerName, blob, this.client.getUrl(), snapshot, versionId, timeout, xMsEncryptionKey, xMsEncryptionKeySha256, xMsEncryptionAlgorithm, this.client.getVersion(), requestId, leaseId, ifModifiedSinceConverted, ifUnmodifiedSinceConverted, ifMatch, ifNoneMatch, context);
}
/**
@@ -383,6 +411,126 @@ public Mono deleteWithRestResponseAsync(String containerNam
return service.delete(containerName, blob, this.client.getUrl(), snapshot, versionId, timeout, deleteSnapshots, this.client.getVersion(), requestId, leaseId, ifModifiedSinceConverted, ifUnmodifiedSinceConverted, ifMatch, ifNoneMatch, context);
}
+ /**
+ * Rename a blob/file. By default, the destination is overwritten and if the destination already exists and has a lease the lease is broken. This operation supports conditional HTTP requests. For more information, see [Specifying Conditional Headers for Blob Service Operations](https://docs.microsoft.com/en-us/rest/api/storageservices/specifying-conditional-headers-for-blob-service-operations). To fail if the destination already exists, use a conditional request with If-None-Match: "*".
+ *
+ * @param filesystem The filesystem name.
+ * @param path The namespace path to a file or directory.
+ * @param renameSource The file or directory to be renamed. The value must have the following format: "/{filesysystem}/{path}". If "x-ms-properties" is specified, the properties will overwrite the existing properties; otherwise, the existing properties will be preserved.
+ * @param context The context to associate with this operation.
+ * @throws IllegalArgumentException thrown if parameters fail the validation.
+ * @return a Mono which performs the network request upon subscription.
+ */
+ @ServiceMethod(returns = ReturnType.SINGLE)
+ public Mono renameWithRestResponseAsync(String filesystem, String path, String renameSource, Context context) {
+ final Integer timeout = null;
+ final String directoryProperties = null;
+ final String posixPermissions = null;
+ final String posixUmask = null;
+ final String sourceLeaseId = null;
+ final String requestId = null;
+ final String cacheControl = null;
+ final String contentType = null;
+ final String contentEncoding = null;
+ final String contentLanguage = null;
+ final String contentDisposition = null;
+ final String leaseId = null;
+ final String ifMatch = null;
+ final String ifNoneMatch = null;
+ final String sourceIfMatch = null;
+ final String sourceIfNoneMatch = null;
+ DateTimeRfc1123 ifModifiedSinceConverted = null;
+ DateTimeRfc1123 ifUnmodifiedSinceConverted = null;
+ DateTimeRfc1123 sourceIfModifiedSinceConverted = null;
+ DateTimeRfc1123 sourceIfUnmodifiedSinceConverted = null;
+ return service.rename(filesystem, path, this.client.getUrl(), timeout, this.client.getPathRenameMode(), renameSource, directoryProperties, posixPermissions, posixUmask, sourceLeaseId, this.client.getVersion(), requestId, cacheControl, contentType, contentEncoding, contentLanguage, contentDisposition, leaseId, ifModifiedSinceConverted, ifUnmodifiedSinceConverted, ifMatch, ifNoneMatch, sourceIfModifiedSinceConverted, sourceIfUnmodifiedSinceConverted, sourceIfMatch, sourceIfNoneMatch, context);
+ }
+
+ /**
+ * Rename a blob/file. By default, the destination is overwritten and if the destination already exists and has a lease the lease is broken. This operation supports conditional HTTP requests. For more information, see [Specifying Conditional Headers for Blob Service Operations](https://docs.microsoft.com/en-us/rest/api/storageservices/specifying-conditional-headers-for-blob-service-operations). To fail if the destination already exists, use a conditional request with If-None-Match: "*".
+ *
+ * @param filesystem The filesystem name.
+ * @param path The namespace path to a file or directory.
+ * @param renameSource The file or directory to be renamed. The value must have the following format: "/{filesysystem}/{path}". If "x-ms-properties" is specified, the properties will overwrite the existing properties; otherwise, the existing properties will be preserved.
+ * @param timeout The timeout parameter is expressed in seconds. For more information, see <a href="https://docs.microsoft.com/en-us/rest/api/storageservices/fileservices/setting-timeouts-for-blob-service-operations">Setting Timeouts for Blob Service Operations.</a>.
+ * @param directoryProperties Optional. User-defined properties to be stored with the file or directory, in the format of a comma-separated list of name and value pairs "n1=v1, n2=v2, ...", where each value is base64 encoded.
+ * @param posixPermissions Optional and only valid if Hierarchical Namespace is enabled for the account. Sets POSIX access permissions for the file owner, the file owning group, and others. Each class may be granted read, write, or execute permission. The sticky bit is also supported. Both symbolic (rwxrw-rw-) and 4-digit octal notation (e.g. 0766) are supported.
+ * @param posixUmask Only valid if Hierarchical Namespace is enabled for the account. This umask restricts permission settings for file and directory, and will only be applied when default Acl does not exist in parent directory. If the umask bit has set, it means that the corresponding permission will be disabled. Otherwise the corresponding permission will be determined by the permission. A 4-digit octal notation (e.g. 0022) is supported here. If no umask was specified, a default umask - 0027 will be used.
+ * @param sourceLeaseId A lease ID for the source path. If specified, the source path must have an active lease and the leaase ID must match.
+ * @param requestId Provides a client-generated, opaque value with a 1 KB character limit that is recorded in the analytics logs when storage analytics logging is enabled.
+ * @param directoryHttpHeaders Additional parameters for the operation.
+ * @param leaseAccessConditions Additional parameters for the operation.
+ * @param modifiedAccessConditions Additional parameters for the operation.
+ * @param sourceModifiedAccessConditions Additional parameters for the operation.
+ * @param context The context to associate with this operation.
+ * @throws IllegalArgumentException thrown if parameters fail the validation.
+ * @return a Mono which performs the network request upon subscription.
+ */
+ @ServiceMethod(returns = ReturnType.SINGLE)
+ public Mono renameWithRestResponseAsync(String filesystem, String path, String renameSource, Integer timeout, String directoryProperties, String posixPermissions, String posixUmask, String sourceLeaseId, String requestId, DirectoryHttpHeaders directoryHttpHeaders, LeaseAccessConditions leaseAccessConditions, ModifiedAccessConditions modifiedAccessConditions, SourceModifiedAccessConditions sourceModifiedAccessConditions, Context context) {
+ String cacheControl = null;
+ if (directoryHttpHeaders != null) {
+ cacheControl = directoryHttpHeaders.cacheControl();
+ }
+ String contentType = null;
+ if (directoryHttpHeaders != null) {
+ contentType = directoryHttpHeaders.contentType();
+ }
+ String contentEncoding = null;
+ if (directoryHttpHeaders != null) {
+ contentEncoding = directoryHttpHeaders.contentEncoding();
+ }
+ String contentLanguage = null;
+ if (directoryHttpHeaders != null) {
+ contentLanguage = directoryHttpHeaders.contentLanguage();
+ }
+ String contentDisposition = null;
+ if (directoryHttpHeaders != null) {
+ contentDisposition = directoryHttpHeaders.contentDisposition();
+ }
+ String leaseId = null;
+ if (leaseAccessConditions != null) {
+ leaseId = leaseAccessConditions.leaseId();
+ }
+ OffsetDateTime ifModifiedSince = null;
+ if (modifiedAccessConditions != null) {
+ ifModifiedSince = modifiedAccessConditions.ifModifiedSince();
+ }
+ OffsetDateTime ifUnmodifiedSince = null;
+ if (modifiedAccessConditions != null) {
+ ifUnmodifiedSince = modifiedAccessConditions.ifUnmodifiedSince();
+ }
+ String ifMatch = null;
+ if (modifiedAccessConditions != null) {
+ ifMatch = modifiedAccessConditions.ifMatch();
+ }
+ String ifNoneMatch = null;
+ if (modifiedAccessConditions != null) {
+ ifNoneMatch = modifiedAccessConditions.ifNoneMatch();
+ }
+ OffsetDateTime sourceIfModifiedSince = null;
+ if (sourceModifiedAccessConditions != null) {
+ sourceIfModifiedSince = sourceModifiedAccessConditions.sourceIfModifiedSince();
+ }
+ OffsetDateTime sourceIfUnmodifiedSince = null;
+ if (sourceModifiedAccessConditions != null) {
+ sourceIfUnmodifiedSince = sourceModifiedAccessConditions.sourceIfUnmodifiedSince();
+ }
+ String sourceIfMatch = null;
+ if (sourceModifiedAccessConditions != null) {
+ sourceIfMatch = sourceModifiedAccessConditions.sourceIfMatch();
+ }
+ String sourceIfNoneMatch = null;
+ if (sourceModifiedAccessConditions != null) {
+ sourceIfNoneMatch = sourceModifiedAccessConditions.sourceIfNoneMatch();
+ }
+ DateTimeRfc1123 ifModifiedSinceConverted = ifModifiedSince == null ? null : new DateTimeRfc1123(ifModifiedSince);
+ DateTimeRfc1123 ifUnmodifiedSinceConverted = ifUnmodifiedSince == null ? null : new DateTimeRfc1123(ifUnmodifiedSince);
+ DateTimeRfc1123 sourceIfModifiedSinceConverted = sourceIfModifiedSince == null ? null : new DateTimeRfc1123(sourceIfModifiedSince);
+ DateTimeRfc1123 sourceIfUnmodifiedSinceConverted = sourceIfUnmodifiedSince == null ? null : new DateTimeRfc1123(sourceIfUnmodifiedSince);
+ return service.rename(filesystem, path, this.client.getUrl(), timeout, this.client.getPathRenameMode(), renameSource, directoryProperties, posixPermissions, posixUmask, sourceLeaseId, this.client.getVersion(), requestId, cacheControl, contentType, contentEncoding, contentLanguage, contentDisposition, leaseId, ifModifiedSinceConverted, ifUnmodifiedSinceConverted, ifMatch, ifNoneMatch, sourceIfModifiedSinceConverted, sourceIfUnmodifiedSinceConverted, sourceIfMatch, sourceIfNoneMatch, context);
+ }
+
/**
* Undelete a blob that was previously soft deleted.
*
@@ -525,17 +673,18 @@ public Mono setHTTPHeadersWithRestResponseAsync(Str
public Mono setMetadataWithRestResponseAsync(String containerName, String blob, Context context) {
final Integer timeout = null;
final Map metadata = null;
- final String encryptionKey = null;
- final String encryptionKeySha256 = null;
- final EncryptionAlgorithmType encryptionAlgorithm = null;
+ final String xMsEncryptionKey = null;
+ final String xMsEncryptionKeySha256 = null;
+ final EncryptionAlgorithmType xMsEncryptionAlgorithm = null;
final String requestId = null;
final String comp = "metadata";
final String leaseId = null;
+ final String encryptionScope = null;
final String ifMatch = null;
final String ifNoneMatch = null;
DateTimeRfc1123 ifModifiedSinceConverted = null;
DateTimeRfc1123 ifUnmodifiedSinceConverted = null;
- return service.setMetadata(containerName, blob, this.client.getUrl(), timeout, metadata, encryptionKey, encryptionKeySha256, encryptionAlgorithm, this.client.getVersion(), requestId, comp, leaseId, ifModifiedSinceConverted, ifUnmodifiedSinceConverted, ifMatch, ifNoneMatch, context);
+ return service.setMetadata(containerName, blob, this.client.getUrl(), timeout, metadata, xMsEncryptionKey, xMsEncryptionKeySha256, xMsEncryptionAlgorithm, this.client.getVersion(), requestId, comp, leaseId, encryptionScope, ifModifiedSinceConverted, ifUnmodifiedSinceConverted, ifMatch, ifNoneMatch, context);
}
/**
@@ -545,23 +694,28 @@ public Mono setMetadataWithRestResponseAsync(String co
* @param blob The blob name.
* @param timeout The timeout parameter is expressed in seconds. For more information, see <a href="https://docs.microsoft.com/en-us/rest/api/storageservices/fileservices/setting-timeouts-for-blob-service-operations">Setting Timeouts for Blob Service Operations.</a>.
* @param metadata Optional. Specifies a user-defined name-value pair associated with the blob. If no name-value pairs are specified, the operation will copy the metadata from the source blob or file to the destination blob. If one or more name-value pairs are specified, the destination blob is created with the specified metadata, and metadata is not copied from the source blob or file. Note that beginning with version 2009-09-19, metadata names must adhere to the naming rules for C# identifiers. See Naming and Referencing Containers, Blobs, and Metadata for more information.
- * @param encryptionKey Optional. Specifies the encryption key to use to encrypt the data provided in the request. If not specified, encryption is performed with the root account encryption key. For more information, see Encryption at Rest for Azure Storage Services.
- * @param encryptionKeySha256 The SHA-256 hash of the provided encryption key. Must be provided if the x-ms-encryption-key header is provided.
- * @param encryptionAlgorithm The algorithm used to produce the encryption key hash. Currently, the only accepted value is "AES256". Must be provided if the x-ms-encryption-key header is provided. Possible values include: 'AES256'.
+ * @param xMsEncryptionKey Optional. Specifies the encryption key to use to encrypt the data provided in the request. If not specified, encryption is performed with the root account encryption key. For more information, see Encryption at Rest for Azure Storage Services.
+ * @param xMsEncryptionKeySha256 The SHA-256 hash of the provided encryption key. Must be provided if the x-ms-encryption-key header is provided.
+ * @param xMsEncryptionAlgorithm The algorithm used to produce the encryption key hash. Currently, the only accepted value is "AES256". Must be provided if the x-ms-encryption-key header is provided. Possible values include: 'AES256'.
* @param requestId Provides a client-generated, opaque value with a 1 KB character limit that is recorded in the analytics logs when storage analytics logging is enabled.
* @param leaseAccessConditions Additional parameters for the operation.
+ * @param customerProvidedKeyInfo Additional parameters for the operation.
* @param modifiedAccessConditions Additional parameters for the operation.
* @param context The context to associate with this operation.
* @throws IllegalArgumentException thrown if parameters fail the validation.
* @return a Mono which performs the network request upon subscription.
*/
@ServiceMethod(returns = ReturnType.SINGLE)
- public Mono setMetadataWithRestResponseAsync(String containerName, String blob, Integer timeout, Map metadata, String encryptionKey, String encryptionKeySha256, EncryptionAlgorithmType encryptionAlgorithm, String requestId, LeaseAccessConditions leaseAccessConditions, ModifiedAccessConditions modifiedAccessConditions, Context context) {
+ public Mono setMetadataWithRestResponseAsync(String containerName, String blob, Integer timeout, Map metadata, String xMsEncryptionKey, String xMsEncryptionKeySha256, EncryptionAlgorithmType xMsEncryptionAlgorithm, String requestId, LeaseAccessConditions leaseAccessConditions, CustomerProvidedKeyInfo customerProvidedKeyInfo, ModifiedAccessConditions modifiedAccessConditions, Context context) {
final String comp = "metadata";
String leaseId = null;
if (leaseAccessConditions != null) {
leaseId = leaseAccessConditions.leaseId();
}
+ String encryptionScope = null;
+ if (customerProvidedKeyInfo != null) {
+ encryptionScope = customerProvidedKeyInfo.encryptionScope();
+ }
OffsetDateTime ifModifiedSince = null;
if (modifiedAccessConditions != null) {
ifModifiedSince = modifiedAccessConditions.ifModifiedSince();
@@ -580,7 +734,7 @@ public Mono setMetadataWithRestResponseAsync(String co
}
DateTimeRfc1123 ifModifiedSinceConverted = ifModifiedSince == null ? null : new DateTimeRfc1123(ifModifiedSince);
DateTimeRfc1123 ifUnmodifiedSinceConverted = ifUnmodifiedSince == null ? null : new DateTimeRfc1123(ifUnmodifiedSince);
- return service.setMetadata(containerName, blob, this.client.getUrl(), timeout, metadata, encryptionKey, encryptionKeySha256, encryptionAlgorithm, this.client.getVersion(), requestId, comp, leaseId, ifModifiedSinceConverted, ifUnmodifiedSinceConverted, ifMatch, ifNoneMatch, context);
+ return service.setMetadata(containerName, blob, this.client.getUrl(), timeout, metadata, xMsEncryptionKey, xMsEncryptionKeySha256, xMsEncryptionAlgorithm, this.client.getVersion(), requestId, comp, leaseId, encryptionScope, ifModifiedSinceConverted, ifUnmodifiedSinceConverted, ifMatch, ifNoneMatch, context);
}
/**
@@ -905,17 +1059,18 @@ public Mono breakLeaseWithRestResponseAsync(String cont
public Mono createSnapshotWithRestResponseAsync(String containerName, String blob, Context context) {
final Integer timeout = null;
final Map metadata = null;
- final String encryptionKey = null;
- final String encryptionKeySha256 = null;
- final EncryptionAlgorithmType encryptionAlgorithm = null;
+ final String xMsEncryptionKey = null;
+ final String xMsEncryptionKeySha256 = null;
+ final EncryptionAlgorithmType xMsEncryptionAlgorithm = null;
final String requestId = null;
final String comp = "snapshot";
+ final String encryptionScope = null;
final String ifMatch = null;
final String ifNoneMatch = null;
final String leaseId = null;
DateTimeRfc1123 ifModifiedSinceConverted = null;
DateTimeRfc1123 ifUnmodifiedSinceConverted = null;
- return service.createSnapshot(containerName, blob, this.client.getUrl(), timeout, metadata, encryptionKey, encryptionKeySha256, encryptionAlgorithm, this.client.getVersion(), requestId, comp, ifModifiedSinceConverted, ifUnmodifiedSinceConverted, ifMatch, ifNoneMatch, leaseId, context);
+ return service.createSnapshot(containerName, blob, this.client.getUrl(), timeout, metadata, xMsEncryptionKey, xMsEncryptionKeySha256, xMsEncryptionAlgorithm, this.client.getVersion(), requestId, comp, encryptionScope, ifModifiedSinceConverted, ifUnmodifiedSinceConverted, ifMatch, ifNoneMatch, leaseId, context);
}
/**
@@ -925,10 +1080,11 @@ public Mono createSnapshotWithRestResponseAsync(Str
* @param blob The blob name.
* @param timeout The timeout parameter is expressed in seconds. For more information, see <a href="https://docs.microsoft.com/en-us/rest/api/storageservices/fileservices/setting-timeouts-for-blob-service-operations">Setting Timeouts for Blob Service Operations.</a>.
* @param metadata Optional. Specifies a user-defined name-value pair associated with the blob. If no name-value pairs are specified, the operation will copy the metadata from the source blob or file to the destination blob. If one or more name-value pairs are specified, the destination blob is created with the specified metadata, and metadata is not copied from the source blob or file. Note that beginning with version 2009-09-19, metadata names must adhere to the naming rules for C# identifiers. See Naming and Referencing Containers, Blobs, and Metadata for more information.
- * @param encryptionKey Optional. Specifies the encryption key to use to encrypt the data provided in the request. If not specified, encryption is performed with the root account encryption key. For more information, see Encryption at Rest for Azure Storage Services.
- * @param encryptionKeySha256 The SHA-256 hash of the provided encryption key. Must be provided if the x-ms-encryption-key header is provided.
- * @param encryptionAlgorithm The algorithm used to produce the encryption key hash. Currently, the only accepted value is "AES256". Must be provided if the x-ms-encryption-key header is provided. Possible values include: 'AES256'.
+ * @param xMsEncryptionKey Optional. Specifies the encryption key to use to encrypt the data provided in the request. If not specified, encryption is performed with the root account encryption key. For more information, see Encryption at Rest for Azure Storage Services.
+ * @param xMsEncryptionKeySha256 The SHA-256 hash of the provided encryption key. Must be provided if the x-ms-encryption-key header is provided.
+ * @param xMsEncryptionAlgorithm The algorithm used to produce the encryption key hash. Currently, the only accepted value is "AES256". Must be provided if the x-ms-encryption-key header is provided. Possible values include: 'AES256'.
* @param requestId Provides a client-generated, opaque value with a 1 KB character limit that is recorded in the analytics logs when storage analytics logging is enabled.
+ * @param customerProvidedKeyInfo Additional parameters for the operation.
* @param modifiedAccessConditions Additional parameters for the operation.
* @param leaseAccessConditions Additional parameters for the operation.
* @param context The context to associate with this operation.
@@ -936,8 +1092,12 @@ public Mono createSnapshotWithRestResponseAsync(Str
* @return a Mono which performs the network request upon subscription.
*/
@ServiceMethod(returns = ReturnType.SINGLE)
- public Mono createSnapshotWithRestResponseAsync(String containerName, String blob, Integer timeout, Map metadata, String encryptionKey, String encryptionKeySha256, EncryptionAlgorithmType encryptionAlgorithm, String requestId, ModifiedAccessConditions modifiedAccessConditions, LeaseAccessConditions leaseAccessConditions, Context context) {
+ public Mono createSnapshotWithRestResponseAsync(String containerName, String blob, Integer timeout, Map metadata, String xMsEncryptionKey, String xMsEncryptionKeySha256, EncryptionAlgorithmType xMsEncryptionAlgorithm, String requestId, CustomerProvidedKeyInfo customerProvidedKeyInfo, ModifiedAccessConditions modifiedAccessConditions, LeaseAccessConditions leaseAccessConditions, Context context) {
final String comp = "snapshot";
+ String encryptionScope = null;
+ if (customerProvidedKeyInfo != null) {
+ encryptionScope = customerProvidedKeyInfo.encryptionScope();
+ }
OffsetDateTime ifModifiedSince = null;
if (modifiedAccessConditions != null) {
ifModifiedSince = modifiedAccessConditions.ifModifiedSince();
@@ -960,7 +1120,7 @@ public Mono createSnapshotWithRestResponseAsync(Str
}
DateTimeRfc1123 ifModifiedSinceConverted = ifModifiedSince == null ? null : new DateTimeRfc1123(ifModifiedSince);
DateTimeRfc1123 ifUnmodifiedSinceConverted = ifUnmodifiedSince == null ? null : new DateTimeRfc1123(ifUnmodifiedSince);
- return service.createSnapshot(containerName, blob, this.client.getUrl(), timeout, metadata, encryptionKey, encryptionKeySha256, encryptionAlgorithm, this.client.getVersion(), requestId, comp, ifModifiedSinceConverted, ifUnmodifiedSinceConverted, ifMatch, ifNoneMatch, leaseId, context);
+ return service.createSnapshot(containerName, blob, this.client.getUrl(), timeout, metadata, xMsEncryptionKey, xMsEncryptionKeySha256, xMsEncryptionAlgorithm, this.client.getVersion(), requestId, comp, encryptionScope, ifModifiedSinceConverted, ifUnmodifiedSinceConverted, ifMatch, ifNoneMatch, leaseId, context);
}
/**
@@ -977,6 +1137,9 @@ public Mono createSnapshotWithRestResponseAsync(Str
public Mono startCopyFromURLWithRestResponseAsync(String containerName, String blob, URL copySource, Context context) {
final Integer timeout = null;
final Map metadata = null;
+ final String tags = null;
+ final AccessTierOptional tier = null;
+ final RehydratePriority rehydratePriority = null;
final String requestId = null;
final String sourceIfMatch = null;
final String sourceIfNoneMatch = null;
@@ -987,7 +1150,7 @@ public Mono startCopyFromURLWithRestResponseAsync
DateTimeRfc1123 sourceIfUnmodifiedSinceConverted = null;
DateTimeRfc1123 ifModifiedSinceConverted = null;
DateTimeRfc1123 ifUnmodifiedSinceConverted = null;
- return service.startCopyFromURL(containerName, blob, this.client.getUrl(), timeout, metadata, copySource, this.client.getVersion(), requestId, sourceIfModifiedSinceConverted, sourceIfUnmodifiedSinceConverted, sourceIfMatch, sourceIfNoneMatch, ifModifiedSinceConverted, ifUnmodifiedSinceConverted, ifMatch, ifNoneMatch, leaseId, context);
+ return service.startCopyFromURL(containerName, blob, this.client.getUrl(), timeout, metadata, tags, tier, rehydratePriority, copySource, this.client.getVersion(), requestId, sourceIfModifiedSinceConverted, sourceIfUnmodifiedSinceConverted, sourceIfMatch, sourceIfNoneMatch, ifModifiedSinceConverted, ifUnmodifiedSinceConverted, ifMatch, ifNoneMatch, leaseId, context);
}
/**
@@ -998,6 +1161,9 @@ public Mono startCopyFromURLWithRestResponseAsync
* @param copySource Specifies the name of the source page blob snapshot. This value is a URL of up to 2 KB in length that specifies a page blob snapshot. The value should be URL-encoded as it would appear in a request URI. The source blob must either be public or must be authenticated via a shared access signature.
* @param timeout The timeout parameter is expressed in seconds. For more information, see <a href="https://docs.microsoft.com/en-us/rest/api/storageservices/fileservices/setting-timeouts-for-blob-service-operations">Setting Timeouts for Blob Service Operations.</a>.
* @param metadata Optional. Specifies a user-defined name-value pair associated with the blob. If no name-value pairs are specified, the operation will copy the metadata from the source blob or file to the destination blob. If one or more name-value pairs are specified, the destination blob is created with the specified metadata, and metadata is not copied from the source blob or file. Note that beginning with version 2009-09-19, metadata names must adhere to the naming rules for C# identifiers. See Naming and Referencing Containers, Blobs, and Metadata for more information.
+ * @param tags Optional. A URL encoded query param string which specifies the tags to be created with the Blob object. e.g. TagName1=TagValue1&TagName2=TagValue2. The x-ms-tags header may contain up to 2kb of tags.
+ * @param tier Optional. Indicates the tier to be set on the blob. Possible values include: 'Hot', 'Cool', 'Archive'.
+ * @param rehydratePriority Optional: Indicates the priority with which to rehydrate an archived blob. Possible values include: 'High', 'Standard'.
* @param requestId Provides a client-generated, opaque value with a 1 KB character limit that is recorded in the analytics logs when storage analytics logging is enabled.
* @param sourceModifiedAccessConditions Additional parameters for the operation.
* @param modifiedAccessConditions Additional parameters for the operation.
@@ -1007,7 +1173,7 @@ public Mono startCopyFromURLWithRestResponseAsync
* @return a Mono which performs the network request upon subscription.
*/
@ServiceMethod(returns = ReturnType.SINGLE)
- public Mono startCopyFromURLWithRestResponseAsync(String containerName, String blob, URL copySource, Integer timeout, Map metadata, String requestId, SourceModifiedAccessConditions sourceModifiedAccessConditions, ModifiedAccessConditions modifiedAccessConditions, LeaseAccessConditions leaseAccessConditions, Context context) {
+ public Mono startCopyFromURLWithRestResponseAsync(String containerName, String blob, URL copySource, Integer timeout, Map metadata, String tags, AccessTierOptional tier, RehydratePriority rehydratePriority, String requestId, SourceModifiedAccessConditions sourceModifiedAccessConditions, ModifiedAccessConditions modifiedAccessConditions, LeaseAccessConditions leaseAccessConditions, Context context) {
OffsetDateTime sourceIfModifiedSince = null;
if (sourceModifiedAccessConditions != null) {
sourceIfModifiedSince = sourceModifiedAccessConditions.sourceIfModifiedSince();
@@ -1048,7 +1214,7 @@ public Mono startCopyFromURLWithRestResponseAsync
DateTimeRfc1123 sourceIfUnmodifiedSinceConverted = sourceIfUnmodifiedSince == null ? null : new DateTimeRfc1123(sourceIfUnmodifiedSince);
DateTimeRfc1123 ifModifiedSinceConverted = ifModifiedSince == null ? null : new DateTimeRfc1123(ifModifiedSince);
DateTimeRfc1123 ifUnmodifiedSinceConverted = ifUnmodifiedSince == null ? null : new DateTimeRfc1123(ifUnmodifiedSince);
- return service.startCopyFromURL(containerName, blob, this.client.getUrl(), timeout, metadata, copySource, this.client.getVersion(), requestId, sourceIfModifiedSinceConverted, sourceIfUnmodifiedSinceConverted, sourceIfMatch, sourceIfNoneMatch, ifModifiedSinceConverted, ifUnmodifiedSinceConverted, ifMatch, ifNoneMatch, leaseId, context);
+ return service.startCopyFromURL(containerName, blob, this.client.getUrl(), timeout, metadata, tags, tier, rehydratePriority, copySource, this.client.getVersion(), requestId, sourceIfModifiedSinceConverted, sourceIfUnmodifiedSinceConverted, sourceIfMatch, sourceIfNoneMatch, ifModifiedSinceConverted, ifUnmodifiedSinceConverted, ifMatch, ifNoneMatch, leaseId, context);
}
/**
@@ -1065,6 +1231,8 @@ public Mono startCopyFromURLWithRestResponseAsync
public Mono copyFromURLWithRestResponseAsync(String containerName, String blob, URL copySource, Context context) {
final Integer timeout = null;
final Map metadata = null;
+ final String tags = null;
+ final AccessTierOptional tier = null;
final String requestId = null;
final String xMsRequiresSync = "true";
final String sourceIfMatch = null;
@@ -1076,7 +1244,7 @@ public Mono copyFromURLWithRestResponseAsync(String co
DateTimeRfc1123 sourceIfUnmodifiedSinceConverted = null;
DateTimeRfc1123 ifModifiedSinceConverted = null;
DateTimeRfc1123 ifUnmodifiedSinceConverted = null;
- return service.copyFromURL(containerName, blob, this.client.getUrl(), timeout, metadata, copySource, this.client.getVersion(), requestId, xMsRequiresSync, sourceIfModifiedSinceConverted, sourceIfUnmodifiedSinceConverted, sourceIfMatch, sourceIfNoneMatch, ifModifiedSinceConverted, ifUnmodifiedSinceConverted, ifMatch, ifNoneMatch, leaseId, context);
+ return service.copyFromURL(containerName, blob, this.client.getUrl(), timeout, metadata, tags, tier, copySource, this.client.getVersion(), requestId, xMsRequiresSync, sourceIfModifiedSinceConverted, sourceIfUnmodifiedSinceConverted, sourceIfMatch, sourceIfNoneMatch, ifModifiedSinceConverted, ifUnmodifiedSinceConverted, ifMatch, ifNoneMatch, leaseId, context);
}
/**
@@ -1087,6 +1255,8 @@ public Mono copyFromURLWithRestResponseAsync(String co
* @param copySource Specifies the name of the source page blob snapshot. This value is a URL of up to 2 KB in length that specifies a page blob snapshot. The value should be URL-encoded as it would appear in a request URI. The source blob must either be public or must be authenticated via a shared access signature.
* @param timeout The timeout parameter is expressed in seconds. For more information, see <a href="https://docs.microsoft.com/en-us/rest/api/storageservices/fileservices/setting-timeouts-for-blob-service-operations">Setting Timeouts for Blob Service Operations.</a>.
* @param metadata Optional. Specifies a user-defined name-value pair associated with the blob. If no name-value pairs are specified, the operation will copy the metadata from the source blob or file to the destination blob. If one or more name-value pairs are specified, the destination blob is created with the specified metadata, and metadata is not copied from the source blob or file. Note that beginning with version 2009-09-19, metadata names must adhere to the naming rules for C# identifiers. See Naming and Referencing Containers, Blobs, and Metadata for more information.
+ * @param tags Optional. A URL encoded query param string which specifies the tags to be created with the Blob object. e.g. TagName1=TagValue1&TagName2=TagValue2. The x-ms-tags header may contain up to 2kb of tags.
+ * @param tier Optional. Indicates the tier to be set on the blob. Possible values include: 'Hot', 'Cool', 'Archive'.
* @param requestId Provides a client-generated, opaque value with a 1 KB character limit that is recorded in the analytics logs when storage analytics logging is enabled.
* @param sourceModifiedAccessConditions Additional parameters for the operation.
* @param modifiedAccessConditions Additional parameters for the operation.
@@ -1096,7 +1266,7 @@ public Mono copyFromURLWithRestResponseAsync(String co
* @return a Mono which performs the network request upon subscription.
*/
@ServiceMethod(returns = ReturnType.SINGLE)
- public Mono copyFromURLWithRestResponseAsync(String containerName, String blob, URL copySource, Integer timeout, Map metadata, String requestId, SourceModifiedAccessConditions sourceModifiedAccessConditions, ModifiedAccessConditions modifiedAccessConditions, LeaseAccessConditions leaseAccessConditions, Context context) {
+ public Mono copyFromURLWithRestResponseAsync(String containerName, String blob, URL copySource, Integer timeout, Map metadata, String tags, AccessTierOptional tier, String requestId, SourceModifiedAccessConditions sourceModifiedAccessConditions, ModifiedAccessConditions modifiedAccessConditions, LeaseAccessConditions leaseAccessConditions, Context context) {
final String xMsRequiresSync = "true";
OffsetDateTime sourceIfModifiedSince = null;
if (sourceModifiedAccessConditions != null) {
@@ -1138,7 +1308,7 @@ public Mono copyFromURLWithRestResponseAsync(String co
DateTimeRfc1123 sourceIfUnmodifiedSinceConverted = sourceIfUnmodifiedSince == null ? null : new DateTimeRfc1123(sourceIfUnmodifiedSince);
DateTimeRfc1123 ifModifiedSinceConverted = ifModifiedSince == null ? null : new DateTimeRfc1123(ifModifiedSince);
DateTimeRfc1123 ifUnmodifiedSinceConverted = ifUnmodifiedSince == null ? null : new DateTimeRfc1123(ifUnmodifiedSince);
- return service.copyFromURL(containerName, blob, this.client.getUrl(), timeout, metadata, copySource, this.client.getVersion(), requestId, xMsRequiresSync, sourceIfModifiedSinceConverted, sourceIfUnmodifiedSinceConverted, sourceIfMatch, sourceIfNoneMatch, ifModifiedSinceConverted, ifUnmodifiedSinceConverted, ifMatch, ifNoneMatch, leaseId, context);
+ return service.copyFromURL(containerName, blob, this.client.getUrl(), timeout, metadata, tags, tier, copySource, this.client.getVersion(), requestId, xMsRequiresSync, sourceIfModifiedSinceConverted, sourceIfUnmodifiedSinceConverted, sourceIfMatch, sourceIfNoneMatch, ifModifiedSinceConverted, ifUnmodifiedSinceConverted, ifMatch, ifNoneMatch, leaseId, context);
}
/**
@@ -1196,12 +1366,13 @@ public Mono abortCopyFromURLWithRestResponseAsync
* @return a Mono which performs the network request upon subscription.
*/
@ServiceMethod(returns = ReturnType.SINGLE)
- public Mono setTierWithRestResponseAsync(String containerName, String blob, AccessTier tier, Context context) {
+ public Mono setTierWithRestResponseAsync(String containerName, String blob, AccessTierRequired tier, Context context) {
final Integer timeout = null;
+ final RehydratePriority rehydratePriority = null;
final String requestId = null;
final String comp = "tier";
final String leaseId = null;
- return service.setTier(containerName, blob, this.client.getUrl(), timeout, tier, this.client.getVersion(), requestId, comp, leaseId, context);
+ return service.setTier(containerName, blob, this.client.getUrl(), timeout, tier, rehydratePriority, this.client.getVersion(), requestId, comp, leaseId, context);
}
/**
@@ -1211,6 +1382,7 @@ public Mono setTierWithRestResponseAsync(String containerN
* @param blob The blob name.
* @param tier Indicates the tier to be set on the blob. Possible values include: 'P4', 'P6', 'P10', 'P20', 'P30', 'P40', 'P50', 'Hot', 'Cool', 'Archive'.
* @param timeout The timeout parameter is expressed in seconds. For more information, see <a href="https://docs.microsoft.com/en-us/rest/api/storageservices/fileservices/setting-timeouts-for-blob-service-operations">Setting Timeouts for Blob Service Operations.</a>.
+ * @param rehydratePriority Optional: Indicates the priority with which to rehydrate an archived blob. Possible values include: 'High', 'Standard'.
* @param requestId Provides a client-generated, opaque value with a 1 KB character limit that is recorded in the analytics logs when storage analytics logging is enabled.
* @param leaseAccessConditions Additional parameters for the operation.
* @param context The context to associate with this operation.
@@ -1218,13 +1390,13 @@ public Mono setTierWithRestResponseAsync(String containerN
* @return a Mono which performs the network request upon subscription.
*/
@ServiceMethod(returns = ReturnType.SINGLE)
- public Mono setTierWithRestResponseAsync(String containerName, String blob, AccessTier tier, Integer timeout, String requestId, LeaseAccessConditions leaseAccessConditions, Context context) {
+ public Mono setTierWithRestResponseAsync(String containerName, String blob, AccessTierRequired tier, Integer timeout, RehydratePriority rehydratePriority, String requestId, LeaseAccessConditions leaseAccessConditions, Context context) {
final String comp = "tier";
String leaseId = null;
if (leaseAccessConditions != null) {
leaseId = leaseAccessConditions.leaseId();
}
- return service.setTier(containerName, blob, this.client.getUrl(), timeout, tier, this.client.getVersion(), requestId, comp, leaseId, context);
+ return service.setTier(containerName, blob, this.client.getUrl(), timeout, tier, rehydratePriority, this.client.getVersion(), requestId, comp, leaseId, context);
}
/**
@@ -1242,4 +1414,88 @@ public Mono getAccountInfoWithRestResponseAsync(Str
final String comp = "properties";
return service.getAccountInfo(containerName, blob, this.client.getUrl(), this.client.getVersion(), restype, comp, context);
}
+
+ /**
+ * The Set Blob Tags operation sets tags for the specified blob. This API is only supported in version 2018-11-09 and later.
+ *
+ * @param containerName The container name.
+ * @param blob The blob name.
+ * @param tags the BlobTags value.
+ * @param contentLength The length of the request.
+ * @param context The context to associate with this operation.
+ * @throws IllegalArgumentException thrown if parameters fail the validation.
+ * @return a Mono which performs the network request upon subscription.
+ */
+ @ServiceMethod(returns = ReturnType.SINGLE)
+ public Mono setTagsWithRestResponseAsync(String containerName, String blob, BlobTags tags, long contentLength, Context context) {
+ final Integer timeout = null;
+ final String requestId = null;
+ final String comp = "tags";
+ String transactionalContentMD5Converted = null;
+ String transactionalContentCrc64Converted = null;
+ return service.setTags(containerName, blob, this.client.getUrl(), tags, timeout, contentLength, transactionalContentMD5Converted, transactionalContentCrc64Converted, this.client.getVersion(), requestId, comp, context);
+ }
+
+ /**
+ * The Set Blob Tags operation sets tags for the specified blob. This API is only supported in version 2018-11-09 and later.
+ *
+ * @param containerName The container name.
+ * @param blob The blob name.
+ * @param tags the BlobTags value.
+ * @param contentLength The length of the request.
+ * @param timeout The timeout parameter is expressed in seconds. For more information, see <a href="https://docs.microsoft.com/en-us/rest/api/storageservices/fileservices/setting-timeouts-for-blob-service-operations">Setting Timeouts for Blob Service Operations.</a>.
+ * @param transactionalContentMD5 Specify the transactional md5 for the body, to be validated by the service.
+ * @param transactionalContentCrc64 Specify the transactional crc64 for the body, to be validated by the service.
+ * @param requestId Provides a client-generated, opaque value with a 1 KB character limit that is recorded in the analytics logs when storage analytics logging is enabled.
+ * @param context The context to associate with this operation.
+ * @throws IllegalArgumentException thrown if parameters fail the validation.
+ * @return a Mono which performs the network request upon subscription.
+ */
+ @ServiceMethod(returns = ReturnType.SINGLE)
+ public Mono setTagsWithRestResponseAsync(String containerName, String blob, BlobTags tags, long contentLength, Integer timeout, byte[] transactionalContentMD5, byte[] transactionalContentCrc64, String requestId, Context context) {
+ final String comp = "tags";
+ String transactionalContentMD5Converted = Base64Util.encodeToString(transactionalContentMD5);
+ String transactionalContentCrc64Converted = Base64Util.encodeToString(transactionalContentCrc64);
+ return service.setTags(containerName, blob, this.client.getUrl(), tags, timeout, contentLength, transactionalContentMD5Converted, transactionalContentCrc64Converted, this.client.getVersion(), requestId, comp, context);
+ }
+
+ /**
+ * The Get Blob Tags operation returns all tags for the specified blob, snapshot, or version. This API is only supported in version 2018-11-09 and later.
+ *
+ * @param containerName The container name.
+ * @param blob The blob name.
+ * @param contentLength The length of the request.
+ * @param context The context to associate with this operation.
+ * @throws IllegalArgumentException thrown if parameters fail the validation.
+ * @return a Mono which performs the network request upon subscription.
+ */
+ @ServiceMethod(returns = ReturnType.SINGLE)
+ public Mono getTagsWithRestResponseAsync(String containerName, String blob, long contentLength, Context context) {
+ final Integer timeout = null;
+ final String snapshot = null;
+ final String versionId = null;
+ final String requestId = null;
+ final String comp = "tags";
+ return service.getTags(containerName, blob, this.client.getUrl(), timeout, contentLength, snapshot, versionId, this.client.getVersion(), requestId, comp, context);
+ }
+
+ /**
+ * The Get Blob Tags operation returns all tags for the specified blob, snapshot, or version. This API is only supported in version 2018-11-09 and later.
+ *
+ * @param containerName The container name.
+ * @param blob The blob name.
+ * @param contentLength The length of the request.
+ * @param timeout The timeout parameter is expressed in seconds. For more information, see <a href="https://docs.microsoft.com/en-us/rest/api/storageservices/fileservices/setting-timeouts-for-blob-service-operations">Setting Timeouts for Blob Service Operations.</a>.
+ * @param snapshot The snapshot parameter is an opaque DateTime value that, when present, specifies the blob snapshot to retrieve. For more information on working with blob snapshots, see <a href="https://docs.microsoft.com/en-us/rest/api/storageservices/fileservices/creating-a-snapshot-of-a-blob">Creating a Snapshot of a Blob.</a>.
+ * @param versionId The version ID parameter is an opaque DateTime value that, when present, specifies the blob version to retrieve.
+ * @param requestId Provides a client-generated, opaque value with a 1 KB character limit that is recorded in the analytics logs when storage analytics logging is enabled.
+ * @param context The context to associate with this operation.
+ * @throws IllegalArgumentException thrown if parameters fail the validation.
+ * @return a Mono which performs the network request upon subscription.
+ */
+ @ServiceMethod(returns = ReturnType.SINGLE)
+ public Mono getTagsWithRestResponseAsync(String containerName, String blob, long contentLength, Integer timeout, String snapshot, String versionId, String requestId, Context context) {
+ final String comp = "tags";
+ return service.getTags(containerName, blob, this.client.getUrl(), timeout, contentLength, snapshot, versionId, this.client.getVersion(), requestId, comp, context);
+ }
}
diff --git a/sdk/storage/azure-storage-blob/src/main/java/com/azure/storage/blob/implementation/BlockBlobsImpl.java b/sdk/storage/azure-storage-blob/src/main/java/com/azure/storage/blob/implementation/BlockBlobsImpl.java
index 390c2436de9a3..ec226b60e1d8a 100644
--- a/sdk/storage/azure-storage-blob/src/main/java/com/azure/storage/blob/implementation/BlockBlobsImpl.java
+++ b/sdk/storage/azure-storage-blob/src/main/java/com/azure/storage/blob/implementation/BlockBlobsImpl.java
@@ -21,6 +21,7 @@
import com.azure.core.implementation.annotation.UnexpectedResponseExceptionType;
import com.azure.core.implementation.util.Base64Util;
import com.azure.core.util.Context;
+import com.azure.storage.blob.models.AccessTierOptional;
import com.azure.storage.blob.models.BlobHTTPHeaders;
import com.azure.storage.blob.models.BlockBlobsCommitBlockListResponse;
import com.azure.storage.blob.models.BlockBlobsGetBlockListResponse;
@@ -29,6 +30,7 @@
import com.azure.storage.blob.models.BlockBlobsUploadResponse;
import com.azure.storage.blob.models.BlockListType;
import com.azure.storage.blob.models.BlockLookupList;
+import com.azure.storage.blob.models.CustomerProvidedKeyInfo;
import com.azure.storage.blob.models.EncryptionAlgorithmType;
import com.azure.storage.blob.models.LeaseAccessConditions;
import com.azure.storage.blob.models.ModifiedAccessConditions;
@@ -76,22 +78,22 @@ private interface BlockBlobsService {
@Put("{containerName}/{blob}")
@ExpectedResponses({201})
@UnexpectedResponseExceptionType(StorageErrorException.class)
- Mono upload(@PathParam("containerName") String containerName, @PathParam("blob") String blob, @HostParam("url") String url, @BodyParam("application/octet-stream") Flux body, @QueryParam("timeout") Integer timeout, @HeaderParam("Content-Length") long contentLength, @HeaderParam("x-ms-meta-") Map metadata, @QueryParam("x-ms-encryption-key") String encryptionKey, @QueryParam("x-ms-encryption-key-sha256") String encryptionKeySha256, @QueryParam("x-ms-encryption-algorithm") EncryptionAlgorithmType encryptionAlgorithm, @HeaderParam("x-ms-version") String version, @HeaderParam("x-ms-client-request-id") String requestId, @HeaderParam("x-ms-blob-type") String blobType, @HeaderParam("x-ms-blob-content-type") String blobContentType, @HeaderParam("x-ms-blob-content-encoding") String blobContentEncoding, @HeaderParam("x-ms-blob-content-language") String blobContentLanguage, @HeaderParam("x-ms-blob-content-md5") String blobContentMD5, @HeaderParam("x-ms-blob-cache-control") String blobCacheControl, @HeaderParam("x-ms-blob-content-disposition") String blobContentDisposition, @HeaderParam("x-ms-lease-id") String leaseId, @HeaderParam("If-Modified-Since") DateTimeRfc1123 ifModifiedSince, @HeaderParam("If-Unmodified-Since") DateTimeRfc1123 ifUnmodifiedSince, @HeaderParam("If-Match") String ifMatch, @HeaderParam("If-None-Match") String ifNoneMatch, Context context);
+ Mono upload(@PathParam("containerName") String containerName, @PathParam("blob") String blob, @HostParam("url") String url, @BodyParam("application/octet-stream") Flux body, @QueryParam("timeout") Integer timeout, @HeaderParam("Content-Length") long contentLength, @HeaderParam("x-ms-meta-") Map metadata, @HeaderParam("x-ms-tags") String tags, @QueryParam("x-ms-encryption-key") String xMsEncryptionKey, @QueryParam("x-ms-encryption-key-sha256") String xMsEncryptionKeySha256, @QueryParam("x-ms-encryption-algorithm") EncryptionAlgorithmType xMsEncryptionAlgorithm, @HeaderParam("x-ms-access-tier") AccessTierOptional tier, @HeaderParam("x-ms-version") String version, @HeaderParam("x-ms-client-request-id") String requestId, @HeaderParam("x-ms-blob-type") String blobType, @HeaderParam("x-ms-blob-content-type") String blobContentType, @HeaderParam("x-ms-blob-content-encoding") String blobContentEncoding, @HeaderParam("x-ms-blob-content-language") String blobContentLanguage, @HeaderParam("x-ms-blob-content-md5") String blobContentMD5, @HeaderParam("x-ms-blob-cache-control") String blobCacheControl, @HeaderParam("x-ms-blob-content-disposition") String blobContentDisposition, @HeaderParam("x-ms-lease-id") String leaseId, @QueryParam("x-ms-encryption-scope") String encryptionScope, @HeaderParam("If-Modified-Since") DateTimeRfc1123 ifModifiedSince, @HeaderParam("If-Unmodified-Since") DateTimeRfc1123 ifUnmodifiedSince, @HeaderParam("If-Match") String ifMatch, @HeaderParam("If-None-Match") String ifNoneMatch, Context context);
@Put("{containerName}/{blob}")
@ExpectedResponses({201})
@UnexpectedResponseExceptionType(StorageErrorException.class)
- Mono stageBlock(@PathParam("containerName") String containerName, @PathParam("blob") String blob, @HostParam("url") String url, @QueryParam("blockid") String blockId, @HeaderParam("Content-Length") long contentLength, @HeaderParam("Content-MD5") String transactionalContentMD5, @BodyParam("application/octet-stream") Flux body, @QueryParam("timeout") Integer timeout, @QueryParam("x-ms-encryption-key") String encryptionKey, @QueryParam("x-ms-encryption-key-sha256") String encryptionKeySha256, @QueryParam("x-ms-encryption-algorithm") EncryptionAlgorithmType encryptionAlgorithm, @HeaderParam("x-ms-version") String version, @HeaderParam("x-ms-client-request-id") String requestId, @QueryParam("comp") String comp, @HeaderParam("x-ms-lease-id") String leaseId, Context context);
+ Mono stageBlock(@PathParam("containerName") String containerName, @PathParam("blob") String blob, @HostParam("url") String url, @QueryParam("blockid") String blockId, @HeaderParam("Content-Length") long contentLength, @HeaderParam("Content-MD5") String transactionalContentMD5, @HeaderParam("x-ms-content-crc64") String transactionalContentCrc64, @BodyParam("application/octet-stream") Flux body, @QueryParam("timeout") Integer timeout, @QueryParam("x-ms-encryption-key") String xMsEncryptionKey, @QueryParam("x-ms-encryption-key-sha256") String xMsEncryptionKeySha256, @QueryParam("x-ms-encryption-algorithm") EncryptionAlgorithmType xMsEncryptionAlgorithm, @HeaderParam("x-ms-version") String version, @HeaderParam("x-ms-client-request-id") String requestId, @QueryParam("comp") String comp, @HeaderParam("x-ms-lease-id") String leaseId, @QueryParam("x-ms-encryption-scope") String encryptionScope, Context context);
@Put("{containerName}/{blob}")
@ExpectedResponses({201})
@UnexpectedResponseExceptionType(StorageErrorException.class)
- Mono stageBlockFromURL(@PathParam("containerName") String containerName, @PathParam("blob") String blob, @HostParam("url") String url, @QueryParam("blockid") String blockId, @HeaderParam("Content-Length") long contentLength, @HeaderParam("x-ms-copy-source") URL copySource, @HeaderParam("x-ms-source-range") String sourceRange, @HeaderParam("x-ms-source-content-md5") String sourceContentMD5, @QueryParam("timeout") Integer timeout, @QueryParam("x-ms-encryption-key") String encryptionKey, @QueryParam("x-ms-encryption-key-sha256") String encryptionKeySha256, @QueryParam("x-ms-encryption-algorithm") EncryptionAlgorithmType encryptionAlgorithm, @HeaderParam("x-ms-version") String version, @HeaderParam("x-ms-client-request-id") String requestId, @QueryParam("comp") String comp, @HeaderParam("x-ms-lease-id") String leaseId, @HeaderParam("x-ms-source-if-modified-since") DateTimeRfc1123 sourceIfModifiedSince, @HeaderParam("x-ms-source-if-unmodified-since") DateTimeRfc1123 sourceIfUnmodifiedSince, @HeaderParam("x-ms-source-if-match") String sourceIfMatch, @HeaderParam("x-ms-source-if-none-match") String sourceIfNoneMatch, Context context);
+ Mono stageBlockFromURL(@PathParam("containerName") String containerName, @PathParam("blob") String blob, @HostParam("url") String url, @QueryParam("blockid") String blockId, @HeaderParam("Content-Length") long contentLength, @HeaderParam("x-ms-copy-source") URL copySource, @HeaderParam("x-ms-source-range") String sourceRange, @HeaderParam("x-ms-source-content-md5") String sourceContentMD5, @HeaderParam("x-ms-source-content-crc64") String sourceContentcrc64, @QueryParam("timeout") Integer timeout, @QueryParam("x-ms-encryption-key") String xMsEncryptionKey, @QueryParam("x-ms-encryption-key-sha256") String xMsEncryptionKeySha256, @QueryParam("x-ms-encryption-algorithm") EncryptionAlgorithmType xMsEncryptionAlgorithm, @HeaderParam("x-ms-version") String version, @HeaderParam("x-ms-client-request-id") String requestId, @QueryParam("comp") String comp, @HeaderParam("x-ms-lease-id") String leaseId, @QueryParam("x-ms-encryption-scope") String encryptionScope, @HeaderParam("x-ms-source-if-modified-since") DateTimeRfc1123 sourceIfModifiedSince, @HeaderParam("x-ms-source-if-unmodified-since") DateTimeRfc1123 sourceIfUnmodifiedSince, @HeaderParam("x-ms-source-if-match") String sourceIfMatch, @HeaderParam("x-ms-source-if-none-match") String sourceIfNoneMatch, Context context);
@Put("{containerName}/{blob}")
@ExpectedResponses({201})
@UnexpectedResponseExceptionType(StorageErrorException.class)
- Mono commitBlockList(@PathParam("containerName") String containerName, @PathParam("blob") String blob, @HostParam("url") String url, @QueryParam("timeout") Integer timeout, @HeaderParam("x-ms-meta-") Map metadata, @QueryParam("x-ms-encryption-key") String encryptionKey, @QueryParam("x-ms-encryption-key-sha256") String encryptionKeySha256, @QueryParam("x-ms-encryption-algorithm") EncryptionAlgorithmType encryptionAlgorithm, @BodyParam("application/xml; charset=utf-8") BlockLookupList blocks, @HeaderParam("x-ms-version") String version, @HeaderParam("x-ms-client-request-id") String requestId, @QueryParam("comp") String comp, @HeaderParam("x-ms-blob-cache-control") String blobCacheControl, @HeaderParam("x-ms-blob-content-type") String blobContentType, @HeaderParam("x-ms-blob-content-encoding") String blobContentEncoding, @HeaderParam("x-ms-blob-content-language") String blobContentLanguage, @HeaderParam("x-ms-blob-content-md5") String blobContentMD5, @HeaderParam("x-ms-blob-content-disposition") String blobContentDisposition, @HeaderParam("x-ms-lease-id") String leaseId, @HeaderParam("If-Modified-Since") DateTimeRfc1123 ifModifiedSince, @HeaderParam("If-Unmodified-Since") DateTimeRfc1123 ifUnmodifiedSince, @HeaderParam("If-Match") String ifMatch, @HeaderParam("If-None-Match") String ifNoneMatch, Context context);
+ Mono commitBlockList(@PathParam("containerName") String containerName, @PathParam("blob") String blob, @HostParam("url") String url, @QueryParam("timeout") Integer timeout, @HeaderParam("Content-MD5") String transactionalContentMD5, @HeaderParam("x-ms-content-crc64") String transactionalContentCrc64, @HeaderParam("x-ms-meta-") Map metadata, @HeaderParam("x-ms-tags") String tags, @QueryParam("x-ms-encryption-key") String xMsEncryptionKey, @QueryParam("x-ms-encryption-key-sha256") String xMsEncryptionKeySha256, @QueryParam("x-ms-encryption-algorithm") EncryptionAlgorithmType xMsEncryptionAlgorithm, @HeaderParam("x-ms-access-tier") AccessTierOptional tier, @BodyParam("application/xml; charset=utf-8") BlockLookupList blocks, @HeaderParam("x-ms-version") String version, @HeaderParam("x-ms-client-request-id") String requestId, @QueryParam("comp") String comp, @HeaderParam("x-ms-blob-cache-control") String blobCacheControl, @HeaderParam("x-ms-blob-content-type") String blobContentType, @HeaderParam("x-ms-blob-content-encoding") String blobContentEncoding, @HeaderParam("x-ms-blob-content-language") String blobContentLanguage, @HeaderParam("x-ms-blob-content-md5") String blobContentMD5, @HeaderParam("x-ms-blob-content-disposition") String blobContentDisposition, @HeaderParam("x-ms-lease-id") String leaseId, @QueryParam("x-ms-encryption-scope") String encryptionScope, @HeaderParam("If-Modified-Since") DateTimeRfc1123 ifModifiedSince, @HeaderParam("If-Unmodified-Since") DateTimeRfc1123 ifUnmodifiedSince, @HeaderParam("If-Match") String ifMatch, @HeaderParam("If-None-Match") String ifNoneMatch, Context context);
@Get("{containerName}/{blob}")
@ExpectedResponses({200})
@@ -114,9 +116,11 @@ private interface BlockBlobsService {
public Mono uploadWithRestResponseAsync(String containerName, String blob, Flux body, long contentLength, Context context) {
final Integer timeout = null;
final Map metadata = null;
- final String encryptionKey = null;
- final String encryptionKeySha256 = null;
- final EncryptionAlgorithmType encryptionAlgorithm = null;
+ final String tags = null;
+ final String xMsEncryptionKey = null;
+ final String xMsEncryptionKeySha256 = null;
+ final EncryptionAlgorithmType xMsEncryptionAlgorithm = null;
+ final AccessTierOptional tier = null;
final String requestId = null;
final String blobType = "BlockBlob";
final String blobContentType = null;
@@ -125,12 +129,13 @@ public Mono uploadWithRestResponseAsync(String contain
final String blobCacheControl = null;
final String blobContentDisposition = null;
final String leaseId = null;
+ final String encryptionScope = null;
final String ifMatch = null;
final String ifNoneMatch = null;
String blobContentMD5Converted = null;
DateTimeRfc1123 ifModifiedSinceConverted = null;
DateTimeRfc1123 ifUnmodifiedSinceConverted = null;
- return service.upload(containerName, blob, this.client.getUrl(), body, timeout, contentLength, metadata, encryptionKey, encryptionKeySha256, encryptionAlgorithm, this.client.getVersion(), requestId, blobType, blobContentType, blobContentEncoding, blobContentLanguage, blobContentMD5Converted, blobCacheControl, blobContentDisposition, leaseId, ifModifiedSinceConverted, ifUnmodifiedSinceConverted, ifMatch, ifNoneMatch, context);
+ return service.upload(containerName, blob, this.client.getUrl(), body, timeout, contentLength, metadata, tags, xMsEncryptionKey, xMsEncryptionKeySha256, xMsEncryptionAlgorithm, tier, this.client.getVersion(), requestId, blobType, blobContentType, blobContentEncoding, blobContentLanguage, blobContentMD5Converted, blobCacheControl, blobContentDisposition, leaseId, encryptionScope, ifModifiedSinceConverted, ifUnmodifiedSinceConverted, ifMatch, ifNoneMatch, context);
}
/**
@@ -142,19 +147,22 @@ public Mono uploadWithRestResponseAsync(String contain
* @param contentLength The length of the request.
* @param timeout The timeout parameter is expressed in seconds. For more information, see <a href="https://docs.microsoft.com/en-us/rest/api/storageservices/fileservices/setting-timeouts-for-blob-service-operations">Setting Timeouts for Blob Service Operations.</a>.
* @param metadata Optional. Specifies a user-defined name-value pair associated with the blob. If no name-value pairs are specified, the operation will copy the metadata from the source blob or file to the destination blob. If one or more name-value pairs are specified, the destination blob is created with the specified metadata, and metadata is not copied from the source blob or file. Note that beginning with version 2009-09-19, metadata names must adhere to the naming rules for C# identifiers. See Naming and Referencing Containers, Blobs, and Metadata for more information.
- * @param encryptionKey Optional. Specifies the encryption key to use to encrypt the data provided in the request. If not specified, encryption is performed with the root account encryption key. For more information, see Encryption at Rest for Azure Storage Services.
- * @param encryptionKeySha256 The SHA-256 hash of the provided encryption key. Must be provided if the x-ms-encryption-key header is provided.
- * @param encryptionAlgorithm The algorithm used to produce the encryption key hash. Currently, the only accepted value is "AES256". Must be provided if the x-ms-encryption-key header is provided. Possible values include: 'AES256'.
+ * @param tags Optional. A URL encoded query param string which specifies the tags to be created with the Blob object. e.g. TagName1=TagValue1&TagName2=TagValue2. The x-ms-tags header may contain up to 2kb of tags.
+ * @param xMsEncryptionKey Optional. Specifies the encryption key to use to encrypt the data provided in the request. If not specified, encryption is performed with the root account encryption key. For more information, see Encryption at Rest for Azure Storage Services.
+ * @param xMsEncryptionKeySha256 The SHA-256 hash of the provided encryption key. Must be provided if the x-ms-encryption-key header is provided.
+ * @param xMsEncryptionAlgorithm The algorithm used to produce the encryption key hash. Currently, the only accepted value is "AES256". Must be provided if the x-ms-encryption-key header is provided. Possible values include: 'AES256'.
+ * @param tier Optional. Indicates the tier to be set on the blob. Possible values include: 'Hot', 'Cool', 'Archive'.
* @param requestId Provides a client-generated, opaque value with a 1 KB character limit that is recorded in the analytics logs when storage analytics logging is enabled.
* @param blobHTTPHeaders Additional parameters for the operation.
* @param leaseAccessConditions Additional parameters for the operation.
+ * @param customerProvidedKeyInfo Additional parameters for the operation.
* @param modifiedAccessConditions Additional parameters for the operation.
* @param context The context to associate with this operation.
* @throws IllegalArgumentException thrown if parameters fail the validation.
* @return a Mono which performs the network request upon subscription.
*/
@ServiceMethod(returns = ReturnType.SINGLE)
- public Mono uploadWithRestResponseAsync(String containerName, String blob, Flux body, long contentLength, Integer timeout, Map metadata, String encryptionKey, String encryptionKeySha256, EncryptionAlgorithmType encryptionAlgorithm, String requestId, BlobHTTPHeaders blobHTTPHeaders, LeaseAccessConditions leaseAccessConditions, ModifiedAccessConditions modifiedAccessConditions, Context context) {
+ public Mono uploadWithRestResponseAsync(String containerName, String blob, Flux body, long contentLength, Integer timeout, Map metadata, String tags, String xMsEncryptionKey, String xMsEncryptionKeySha256, EncryptionAlgorithmType xMsEncryptionAlgorithm, AccessTierOptional tier, String requestId, BlobHTTPHeaders blobHTTPHeaders, LeaseAccessConditions leaseAccessConditions, CustomerProvidedKeyInfo customerProvidedKeyInfo, ModifiedAccessConditions modifiedAccessConditions, Context context) {
final String blobType = "BlockBlob";
String blobContentType = null;
if (blobHTTPHeaders != null) {
@@ -184,6 +192,10 @@ public Mono uploadWithRestResponseAsync(String contain
if (leaseAccessConditions != null) {
leaseId = leaseAccessConditions.leaseId();
}
+ String encryptionScope = null;
+ if (customerProvidedKeyInfo != null) {
+ encryptionScope = customerProvidedKeyInfo.encryptionScope();
+ }
OffsetDateTime ifModifiedSince = null;
if (modifiedAccessConditions != null) {
ifModifiedSince = modifiedAccessConditions.ifModifiedSince();
@@ -203,7 +215,7 @@ public Mono uploadWithRestResponseAsync(String contain
String blobContentMD5Converted = Base64Util.encodeToString(blobContentMD5);
DateTimeRfc1123 ifModifiedSinceConverted = ifModifiedSince == null ? null : new DateTimeRfc1123(ifModifiedSince);
DateTimeRfc1123 ifUnmodifiedSinceConverted = ifUnmodifiedSince == null ? null : new DateTimeRfc1123(ifUnmodifiedSince);
- return service.upload(containerName, blob, this.client.getUrl(), body, timeout, contentLength, metadata, encryptionKey, encryptionKeySha256, encryptionAlgorithm, this.client.getVersion(), requestId, blobType, blobContentType, blobContentEncoding, blobContentLanguage, blobContentMD5Converted, blobCacheControl, blobContentDisposition, leaseId, ifModifiedSinceConverted, ifUnmodifiedSinceConverted, ifMatch, ifNoneMatch, context);
+ return service.upload(containerName, blob, this.client.getUrl(), body, timeout, contentLength, metadata, tags, xMsEncryptionKey, xMsEncryptionKeySha256, xMsEncryptionAlgorithm, tier, this.client.getVersion(), requestId, blobType, blobContentType, blobContentEncoding, blobContentLanguage, blobContentMD5Converted, blobCacheControl, blobContentDisposition, leaseId, encryptionScope, ifModifiedSinceConverted, ifUnmodifiedSinceConverted, ifMatch, ifNoneMatch, context);
}
/**
@@ -221,14 +233,16 @@ public Mono uploadWithRestResponseAsync(String contain
@ServiceMethod(returns = ReturnType.SINGLE)
public Mono stageBlockWithRestResponseAsync(String containerName, String blob, String blockId, long contentLength, Flux body, Context context) {
final Integer timeout = null;
- final String encryptionKey = null;
- final String encryptionKeySha256 = null;
- final EncryptionAlgorithmType encryptionAlgorithm = null;
+ final String xMsEncryptionKey = null;
+ final String xMsEncryptionKeySha256 = null;
+ final EncryptionAlgorithmType xMsEncryptionAlgorithm = null;
final String requestId = null;
final String comp = "block";
final String leaseId = null;
+ final String encryptionScope = null;
String transactionalContentMD5Converted = null;
- return service.stageBlock(containerName, blob, this.client.getUrl(), blockId, contentLength, transactionalContentMD5Converted, body, timeout, encryptionKey, encryptionKeySha256, encryptionAlgorithm, this.client.getVersion(), requestId, comp, leaseId, context);
+ String transactionalContentCrc64Converted = null;
+ return service.stageBlock(containerName, blob, this.client.getUrl(), blockId, contentLength, transactionalContentMD5Converted, transactionalContentCrc64Converted, body, timeout, xMsEncryptionKey, xMsEncryptionKeySha256, xMsEncryptionAlgorithm, this.client.getVersion(), requestId, comp, leaseId, encryptionScope, context);
}
/**
@@ -240,25 +254,32 @@ public Mono stageBlockWithRestResponseAsync(String
* @param contentLength The length of the request.
* @param body Initial data.
* @param transactionalContentMD5 Specify the transactional md5 for the body, to be validated by the service.
+ * @param transactionalContentCrc64 Specify the transactional crc64 for the body, to be validated by the service.
* @param timeout The timeout parameter is expressed in seconds. For more information, see <a href="https://docs.microsoft.com/en-us/rest/api/storageservices/fileservices/setting-timeouts-for-blob-service-operations">Setting Timeouts for Blob Service Operations.</a>.
- * @param encryptionKey Optional. Specifies the encryption key to use to encrypt the data provided in the request. If not specified, encryption is performed with the root account encryption key. For more information, see Encryption at Rest for Azure Storage Services.
- * @param encryptionKeySha256 The SHA-256 hash of the provided encryption key. Must be provided if the x-ms-encryption-key header is provided.
- * @param encryptionAlgorithm The algorithm used to produce the encryption key hash. Currently, the only accepted value is "AES256". Must be provided if the x-ms-encryption-key header is provided. Possible values include: 'AES256'.
+ * @param xMsEncryptionKey Optional. Specifies the encryption key to use to encrypt the data provided in the request. If not specified, encryption is performed with the root account encryption key. For more information, see Encryption at Rest for Azure Storage Services.
+ * @param xMsEncryptionKeySha256 The SHA-256 hash of the provided encryption key. Must be provided if the x-ms-encryption-key header is provided.
+ * @param xMsEncryptionAlgorithm The algorithm used to produce the encryption key hash. Currently, the only accepted value is "AES256". Must be provided if the x-ms-encryption-key header is provided. Possible values include: 'AES256'.
* @param requestId Provides a client-generated, opaque value with a 1 KB character limit that is recorded in the analytics logs when storage analytics logging is enabled.
* @param leaseAccessConditions Additional parameters for the operation.
+ * @param customerProvidedKeyInfo Additional parameters for the operation.
* @param context The context to associate with this operation.
* @throws IllegalArgumentException thrown if parameters fail the validation.
* @return a Mono which performs the network request upon subscription.
*/
@ServiceMethod(returns = ReturnType.SINGLE)
- public Mono stageBlockWithRestResponseAsync(String containerName, String blob, String blockId, long contentLength, Flux body, byte[] transactionalContentMD5, Integer timeout, String encryptionKey, String encryptionKeySha256, EncryptionAlgorithmType encryptionAlgorithm, String requestId, LeaseAccessConditions leaseAccessConditions, Context context) {
+ public Mono stageBlockWithRestResponseAsync(String containerName, String blob, String blockId, long contentLength, Flux body, byte[] transactionalContentMD5, byte[] transactionalContentCrc64, Integer timeout, String xMsEncryptionKey, String xMsEncryptionKeySha256, EncryptionAlgorithmType xMsEncryptionAlgorithm, String requestId, LeaseAccessConditions leaseAccessConditions, CustomerProvidedKeyInfo customerProvidedKeyInfo, Context context) {
final String comp = "block";
String leaseId = null;
if (leaseAccessConditions != null) {
leaseId = leaseAccessConditions.leaseId();
}
+ String encryptionScope = null;
+ if (customerProvidedKeyInfo != null) {
+ encryptionScope = customerProvidedKeyInfo.encryptionScope();
+ }
String transactionalContentMD5Converted = Base64Util.encodeToString(transactionalContentMD5);
- return service.stageBlock(containerName, blob, this.client.getUrl(), blockId, contentLength, transactionalContentMD5Converted, body, timeout, encryptionKey, encryptionKeySha256, encryptionAlgorithm, this.client.getVersion(), requestId, comp, leaseId, context);
+ String transactionalContentCrc64Converted = Base64Util.encodeToString(transactionalContentCrc64);
+ return service.stageBlock(containerName, blob, this.client.getUrl(), blockId, contentLength, transactionalContentMD5Converted, transactionalContentCrc64Converted, body, timeout, xMsEncryptionKey, xMsEncryptionKeySha256, xMsEncryptionAlgorithm, this.client.getVersion(), requestId, comp, leaseId, encryptionScope, context);
}
/**
@@ -277,18 +298,20 @@ public Mono stageBlockWithRestResponseAsync(String
public Mono stageBlockFromURLWithRestResponseAsync(String containerName, String blob, String blockId, long contentLength, URL sourceUrl, Context context) {
final String sourceRange = null;
final Integer timeout = null;
- final String encryptionKey = null;
- final String encryptionKeySha256 = null;
- final EncryptionAlgorithmType encryptionAlgorithm = null;
+ final String xMsEncryptionKey = null;
+ final String xMsEncryptionKeySha256 = null;
+ final EncryptionAlgorithmType xMsEncryptionAlgorithm = null;
final String requestId = null;
final String comp = "block";
final String leaseId = null;
+ final String encryptionScope = null;
final String sourceIfMatch = null;
final String sourceIfNoneMatch = null;
String sourceContentMD5Converted = null;
+ String sourceContentcrc64Converted = null;
DateTimeRfc1123 sourceIfModifiedSinceConverted = null;
DateTimeRfc1123 sourceIfUnmodifiedSinceConverted = null;
- return service.stageBlockFromURL(containerName, blob, this.client.getUrl(), blockId, contentLength, sourceUrl, sourceRange, sourceContentMD5Converted, timeout, encryptionKey, encryptionKeySha256, encryptionAlgorithm, this.client.getVersion(), requestId, comp, leaseId, sourceIfModifiedSinceConverted, sourceIfUnmodifiedSinceConverted, sourceIfMatch, sourceIfNoneMatch, context);
+ return service.stageBlockFromURL(containerName, blob, this.client.getUrl(), blockId, contentLength, sourceUrl, sourceRange, sourceContentMD5Converted, sourceContentcrc64Converted, timeout, xMsEncryptionKey, xMsEncryptionKeySha256, xMsEncryptionAlgorithm, this.client.getVersion(), requestId, comp, leaseId, encryptionScope, sourceIfModifiedSinceConverted, sourceIfUnmodifiedSinceConverted, sourceIfMatch, sourceIfNoneMatch, context);
}
/**
@@ -301,24 +324,30 @@ public Mono stageBlockFromURLWithRestRespon
* @param sourceUrl Specify a URL to the copy source.
* @param sourceRange Bytes of source data in the specified range.
* @param sourceContentMD5 Specify the md5 calculated for the range of bytes that must be read from the copy source.
+ * @param sourceContentcrc64 Specify the crc64 calculated for the range of bytes that must be read from the copy source.
* @param timeout The timeout parameter is expressed in seconds. For more information, see <a href="https://docs.microsoft.com/en-us/rest/api/storageservices/fileservices/setting-timeouts-for-blob-service-operations">Setting Timeouts for Blob Service Operations.</a>.
- * @param encryptionKey Optional. Specifies the encryption key to use to encrypt the data provided in the request. If not specified, encryption is performed with the root account encryption key. For more information, see Encryption at Rest for Azure Storage Services.
- * @param encryptionKeySha256 The SHA-256 hash of the provided encryption key. Must be provided if the x-ms-encryption-key header is provided.
- * @param encryptionAlgorithm The algorithm used to produce the encryption key hash. Currently, the only accepted value is "AES256". Must be provided if the x-ms-encryption-key header is provided. Possible values include: 'AES256'.
+ * @param xMsEncryptionKey Optional. Specifies the encryption key to use to encrypt the data provided in the request. If not specified, encryption is performed with the root account encryption key. For more information, see Encryption at Rest for Azure Storage Services.
+ * @param xMsEncryptionKeySha256 The SHA-256 hash of the provided encryption key. Must be provided if the x-ms-encryption-key header is provided.
+ * @param xMsEncryptionAlgorithm The algorithm used to produce the encryption key hash. Currently, the only accepted value is "AES256". Must be provided if the x-ms-encryption-key header is provided. Possible values include: 'AES256'.
* @param requestId Provides a client-generated, opaque value with a 1 KB character limit that is recorded in the analytics logs when storage analytics logging is enabled.
* @param leaseAccessConditions Additional parameters for the operation.
+ * @param customerProvidedKeyInfo Additional parameters for the operation.
* @param sourceModifiedAccessConditions Additional parameters for the operation.
* @param context The context to associate with this operation.
* @throws IllegalArgumentException thrown if parameters fail the validation.
* @return a Mono which performs the network request upon subscription.
*/
@ServiceMethod(returns = ReturnType.SINGLE)
- public Mono stageBlockFromURLWithRestResponseAsync(String containerName, String blob, String blockId, long contentLength, URL sourceUrl, String sourceRange, byte[] sourceContentMD5, Integer timeout, String encryptionKey, String encryptionKeySha256, EncryptionAlgorithmType encryptionAlgorithm, String requestId, LeaseAccessConditions leaseAccessConditions, SourceModifiedAccessConditions sourceModifiedAccessConditions, Context context) {
+ public Mono stageBlockFromURLWithRestResponseAsync(String containerName, String blob, String blockId, long contentLength, URL sourceUrl, String sourceRange, byte[] sourceContentMD5, byte[] sourceContentcrc64, Integer timeout, String xMsEncryptionKey, String xMsEncryptionKeySha256, EncryptionAlgorithmType xMsEncryptionAlgorithm, String requestId, LeaseAccessConditions leaseAccessConditions, CustomerProvidedKeyInfo customerProvidedKeyInfo, SourceModifiedAccessConditions sourceModifiedAccessConditions, Context context) {
final String comp = "block";
String leaseId = null;
if (leaseAccessConditions != null) {
leaseId = leaseAccessConditions.leaseId();
}
+ String encryptionScope = null;
+ if (customerProvidedKeyInfo != null) {
+ encryptionScope = customerProvidedKeyInfo.encryptionScope();
+ }
OffsetDateTime sourceIfModifiedSince = null;
if (sourceModifiedAccessConditions != null) {
sourceIfModifiedSince = sourceModifiedAccessConditions.sourceIfModifiedSince();
@@ -336,9 +365,10 @@ public Mono stageBlockFromURLWithRestRespon
sourceIfNoneMatch = sourceModifiedAccessConditions.sourceIfNoneMatch();
}
String sourceContentMD5Converted = Base64Util.encodeToString(sourceContentMD5);
+ String sourceContentcrc64Converted = Base64Util.encodeToString(sourceContentcrc64);
DateTimeRfc1123 sourceIfModifiedSinceConverted = sourceIfModifiedSince == null ? null : new DateTimeRfc1123(sourceIfModifiedSince);
DateTimeRfc1123 sourceIfUnmodifiedSinceConverted = sourceIfUnmodifiedSince == null ? null : new DateTimeRfc1123(sourceIfUnmodifiedSince);
- return service.stageBlockFromURL(containerName, blob, this.client.getUrl(), blockId, contentLength, sourceUrl, sourceRange, sourceContentMD5Converted, timeout, encryptionKey, encryptionKeySha256, encryptionAlgorithm, this.client.getVersion(), requestId, comp, leaseId, sourceIfModifiedSinceConverted, sourceIfUnmodifiedSinceConverted, sourceIfMatch, sourceIfNoneMatch, context);
+ return service.stageBlockFromURL(containerName, blob, this.client.getUrl(), blockId, contentLength, sourceUrl, sourceRange, sourceContentMD5Converted, sourceContentcrc64Converted, timeout, xMsEncryptionKey, xMsEncryptionKeySha256, xMsEncryptionAlgorithm, this.client.getVersion(), requestId, comp, leaseId, encryptionScope, sourceIfModifiedSinceConverted, sourceIfUnmodifiedSinceConverted, sourceIfMatch, sourceIfNoneMatch, context);
}
/**
@@ -355,9 +385,11 @@ public Mono stageBlockFromURLWithRestRespon
public Mono commitBlockListWithRestResponseAsync(String containerName, String blob, BlockLookupList blocks, Context context) {
final Integer timeout = null;
final Map metadata = null;
- final String encryptionKey = null;
- final String encryptionKeySha256 = null;
- final EncryptionAlgorithmType encryptionAlgorithm = null;
+ final String tags = null;
+ final String xMsEncryptionKey = null;
+ final String xMsEncryptionKeySha256 = null;
+ final EncryptionAlgorithmType xMsEncryptionAlgorithm = null;
+ final AccessTierOptional tier = null;
final String requestId = null;
final String comp = "blocklist";
final String blobCacheControl = null;
@@ -366,12 +398,15 @@ public Mono commitBlockListWithRestResponseAs
final String blobContentLanguage = null;
final String blobContentDisposition = null;
final String leaseId = null;
+ final String encryptionScope = null;
final String ifMatch = null;
final String ifNoneMatch = null;
+ String transactionalContentMD5Converted = null;
+ String transactionalContentCrc64Converted = null;
String blobContentMD5Converted = null;
DateTimeRfc1123 ifModifiedSinceConverted = null;
DateTimeRfc1123 ifUnmodifiedSinceConverted = null;
- return service.commitBlockList(containerName, blob, this.client.getUrl(), timeout, metadata, encryptionKey, encryptionKeySha256, encryptionAlgorithm, blocks, this.client.getVersion(), requestId, comp, blobCacheControl, blobContentType, blobContentEncoding, blobContentLanguage, blobContentMD5Converted, blobContentDisposition, leaseId, ifModifiedSinceConverted, ifUnmodifiedSinceConverted, ifMatch, ifNoneMatch, context);
+ return service.commitBlockList(containerName, blob, this.client.getUrl(), timeout, transactionalContentMD5Converted, transactionalContentCrc64Converted, metadata, tags, xMsEncryptionKey, xMsEncryptionKeySha256, xMsEncryptionAlgorithm, tier, blocks, this.client.getVersion(), requestId, comp, blobCacheControl, blobContentType, blobContentEncoding, blobContentLanguage, blobContentMD5Converted, blobContentDisposition, leaseId, encryptionScope, ifModifiedSinceConverted, ifUnmodifiedSinceConverted, ifMatch, ifNoneMatch, context);
}
/**
@@ -381,20 +416,25 @@ public Mono commitBlockListWithRestResponseAs
* @param blob The blob name.
* @param blocks the BlockLookupList value.
* @param timeout The timeout parameter is expressed in seconds. For more information, see <a href="https://docs.microsoft.com/en-us/rest/api/storageservices/fileservices/setting-timeouts-for-blob-service-operations">Setting Timeouts for Blob Service Operations.</a>.
+ * @param transactionalContentMD5 Specify the transactional md5 for the body, to be validated by the service.
+ * @param transactionalContentCrc64 Specify the transactional crc64 for the body, to be validated by the service.
* @param metadata Optional. Specifies a user-defined name-value pair associated with the blob. If no name-value pairs are specified, the operation will copy the metadata from the source blob or file to the destination blob. If one or more name-value pairs are specified, the destination blob is created with the specified metadata, and metadata is not copied from the source blob or file. Note that beginning with version 2009-09-19, metadata names must adhere to the naming rules for C# identifiers. See Naming and Referencing Containers, Blobs, and Metadata for more information.
- * @param encryptionKey Optional. Specifies the encryption key to use to encrypt the data provided in the request. If not specified, encryption is performed with the root account encryption key. For more information, see Encryption at Rest for Azure Storage Services.
- * @param encryptionKeySha256 The SHA-256 hash of the provided encryption key. Must be provided if the x-ms-encryption-key header is provided.
- * @param encryptionAlgorithm The algorithm used to produce the encryption key hash. Currently, the only accepted value is "AES256". Must be provided if the x-ms-encryption-key header is provided. Possible values include: 'AES256'.
+ * @param tags Optional. A URL encoded query param string which specifies the tags to be created with the Blob object. e.g. TagName1=TagValue1&TagName2=TagValue2. The x-ms-tags header may contain up to 2kb of tags.
+ * @param xMsEncryptionKey Optional. Specifies the encryption key to use to encrypt the data provided in the request. If not specified, encryption is performed with the root account encryption key. For more information, see Encryption at Rest for Azure Storage Services.
+ * @param xMsEncryptionKeySha256 The SHA-256 hash of the provided encryption key. Must be provided if the x-ms-encryption-key header is provided.
+ * @param xMsEncryptionAlgorithm The algorithm used to produce the encryption key hash. Currently, the only accepted value is "AES256". Must be provided if the x-ms-encryption-key header is provided. Possible values include: 'AES256'.
+ * @param tier Optional. Indicates the tier to be set on the blob. Possible values include: 'Hot', 'Cool', 'Archive'.
* @param requestId Provides a client-generated, opaque value with a 1 KB character limit that is recorded in the analytics logs when storage analytics logging is enabled.
* @param blobHTTPHeaders Additional parameters for the operation.
* @param leaseAccessConditions Additional parameters for the operation.
+ * @param customerProvidedKeyInfo Additional parameters for the operation.
* @param modifiedAccessConditions Additional parameters for the operation.
* @param context The context to associate with this operation.
* @throws IllegalArgumentException thrown if parameters fail the validation.
* @return a Mono which performs the network request upon subscription.
*/
@ServiceMethod(returns = ReturnType.SINGLE)
- public Mono commitBlockListWithRestResponseAsync(String containerName, String blob, BlockLookupList blocks, Integer timeout, Map metadata, String encryptionKey, String encryptionKeySha256, EncryptionAlgorithmType encryptionAlgorithm, String requestId, BlobHTTPHeaders blobHTTPHeaders, LeaseAccessConditions leaseAccessConditions, ModifiedAccessConditions modifiedAccessConditions, Context context) {
+ public Mono commitBlockListWithRestResponseAsync(String containerName, String blob, BlockLookupList blocks, Integer timeout, byte[] transactionalContentMD5, byte[] transactionalContentCrc64, Map metadata, String tags, String xMsEncryptionKey, String xMsEncryptionKeySha256, EncryptionAlgorithmType xMsEncryptionAlgorithm, AccessTierOptional tier, String requestId, BlobHTTPHeaders blobHTTPHeaders, LeaseAccessConditions leaseAccessConditions, CustomerProvidedKeyInfo customerProvidedKeyInfo, ModifiedAccessConditions modifiedAccessConditions, Context context) {
final String comp = "blocklist";
String blobCacheControl = null;
if (blobHTTPHeaders != null) {
@@ -424,6 +464,10 @@ public Mono commitBlockListWithRestResponseAs
if (leaseAccessConditions != null) {
leaseId = leaseAccessConditions.leaseId();
}
+ String encryptionScope = null;
+ if (customerProvidedKeyInfo != null) {
+ encryptionScope = customerProvidedKeyInfo.encryptionScope();
+ }
OffsetDateTime ifModifiedSince = null;
if (modifiedAccessConditions != null) {
ifModifiedSince = modifiedAccessConditions.ifModifiedSince();
@@ -440,10 +484,12 @@ public Mono commitBlockListWithRestResponseAs
if (modifiedAccessConditions != null) {
ifNoneMatch = modifiedAccessConditions.ifNoneMatch();
}
+ String transactionalContentMD5Converted = Base64Util.encodeToString(transactionalContentMD5);
+ String transactionalContentCrc64Converted = Base64Util.encodeToString(transactionalContentCrc64);
String blobContentMD5Converted = Base64Util.encodeToString(blobContentMD5);
DateTimeRfc1123 ifModifiedSinceConverted = ifModifiedSince == null ? null : new DateTimeRfc1123(ifModifiedSince);
DateTimeRfc1123 ifUnmodifiedSinceConverted = ifUnmodifiedSince == null ? null : new DateTimeRfc1123(ifUnmodifiedSince);
- return service.commitBlockList(containerName, blob, this.client.getUrl(), timeout, metadata, encryptionKey, encryptionKeySha256, encryptionAlgorithm, blocks, this.client.getVersion(), requestId, comp, blobCacheControl, blobContentType, blobContentEncoding, blobContentLanguage, blobContentMD5Converted, blobContentDisposition, leaseId, ifModifiedSinceConverted, ifUnmodifiedSinceConverted, ifMatch, ifNoneMatch, context);
+ return service.commitBlockList(containerName, blob, this.client.getUrl(), timeout, transactionalContentMD5Converted, transactionalContentCrc64Converted, metadata, tags, xMsEncryptionKey, xMsEncryptionKeySha256, xMsEncryptionAlgorithm, tier, blocks, this.client.getVersion(), requestId, comp, blobCacheControl, blobContentType, blobContentEncoding, blobContentLanguage, blobContentMD5Converted, blobContentDisposition, leaseId, encryptionScope, ifModifiedSinceConverted, ifUnmodifiedSinceConverted, ifMatch, ifNoneMatch, context);
}
/**
diff --git a/sdk/storage/azure-storage-blob/src/main/java/com/azure/storage/blob/implementation/ContainersImpl.java b/sdk/storage/azure-storage-blob/src/main/java/com/azure/storage/blob/implementation/ContainersImpl.java
index efb3b64cdf8b5..5a594d600a855 100644
--- a/sdk/storage/azure-storage-blob/src/main/java/com/azure/storage/blob/implementation/ContainersImpl.java
+++ b/sdk/storage/azure-storage-blob/src/main/java/com/azure/storage/blob/implementation/ContainersImpl.java
@@ -83,7 +83,7 @@ private interface ContainersService {
@Put("{containerName}")
@ExpectedResponses({201})
@UnexpectedResponseExceptionType(StorageErrorException.class)
- Mono create(@PathParam("containerName") String containerName, @HostParam("url") String url, @QueryParam("timeout") Integer timeout, @HeaderParam("x-ms-meta-") Map metadata, @HeaderParam("x-ms-blob-public-access") PublicAccessType access, @HeaderParam("x-ms-version") String version, @HeaderParam("x-ms-client-request-id") String requestId, @QueryParam("restype") String restype, Context context);
+ Mono create(@PathParam("containerName") String containerName, @HostParam("url") String url, @QueryParam("timeout") Integer timeout, @HeaderParam("x-ms-meta-") Map metadata, @HeaderParam("x-ms-blob-public-access") PublicAccessType access, @HeaderParam("x-ms-default-encryption-scope") String defaultEncryptionScope, @HeaderParam("x-ms-deny-encryption-scope-override") Boolean denyEncryptionScopeOverride, @HeaderParam("x-ms-version") String version, @HeaderParam("x-ms-client-request-id") String requestId, @QueryParam("restype") String restype, Context context);
@Get("{containerName}")
@ExpectedResponses({200})
@@ -138,12 +138,12 @@ private interface ContainersService {
@Get("{containerName}")
@ExpectedResponses({200})
@UnexpectedResponseExceptionType(StorageErrorException.class)
- Mono listBlobFlatSegment(@PathParam("containerName") String containerName, @HostParam("url") String url, @QueryParam("prefix") String prefix, @QueryParam("marker") String marker, @QueryParam("maxresults") Integer maxresults, @QueryParam("include") String include, @QueryParam("timeout") Integer timeout, @HeaderParam("x-ms-version") String version, @HeaderParam("x-ms-client-request-id") String requestId, @QueryParam("restype") String restype, @QueryParam("comp") String comp, Context context);
+ Mono listBlobFlatSegment(@PathParam("containerName") String containerName, @HostParam("url") String url, @QueryParam("prefix") String prefix, @QueryParam("marker") String marker1, @QueryParam("maxresults") Integer maxresults, @QueryParam("include") String include, @QueryParam("timeout") Integer timeout, @HeaderParam("x-ms-version") String version, @HeaderParam("x-ms-client-request-id") String requestId, @QueryParam("restype") String restype, @QueryParam("comp") String comp, Context context);
@Get("{containerName}")
@ExpectedResponses({200})
@UnexpectedResponseExceptionType(StorageErrorException.class)
- Mono listBlobHierarchySegment(@PathParam("containerName") String containerName, @HostParam("url") String url, @QueryParam("prefix") String prefix, @QueryParam("delimiter") String delimiter, @QueryParam("marker") String marker, @QueryParam("maxresults") Integer maxresults, @QueryParam("include") String include, @QueryParam("timeout") Integer timeout, @HeaderParam("x-ms-version") String version, @HeaderParam("x-ms-client-request-id") String requestId, @QueryParam("restype") String restype, @QueryParam("comp") String comp, Context context);
+ Mono listBlobHierarchySegment(@PathParam("containerName") String containerName, @HostParam("url") String url, @QueryParam("prefix") String prefix, @QueryParam("delimiter") String delimiter, @QueryParam("marker") String marker1, @QueryParam("maxresults") Integer maxresults, @QueryParam("include") String include, @QueryParam("timeout") Integer timeout, @HeaderParam("x-ms-version") String version, @HeaderParam("x-ms-client-request-id") String requestId, @QueryParam("restype") String restype, @QueryParam("comp") String comp, Context context);
@Get("{containerName}")
@ExpectedResponses({200})
@@ -164,9 +164,11 @@ public Mono createWithRestResponseAsync(String contain
final Integer timeout = null;
final Map metadata = null;
final PublicAccessType access = null;
+ final String defaultEncryptionScope = null;
+ final Boolean denyEncryptionScopeOverride = null;
final String requestId = null;
final String restype = "container";
- return service.create(containerName, this.client.getUrl(), timeout, metadata, access, this.client.getVersion(), requestId, restype, context);
+ return service.create(containerName, this.client.getUrl(), timeout, metadata, access, defaultEncryptionScope, denyEncryptionScopeOverride, this.client.getVersion(), requestId, restype, context);
}
/**
@@ -176,15 +178,17 @@ public Mono createWithRestResponseAsync(String contain
* @param timeout The timeout parameter is expressed in seconds. For more information, see <a href="https://docs.microsoft.com/en-us/rest/api/storageservices/fileservices/setting-timeouts-for-blob-service-operations">Setting Timeouts for Blob Service Operations.</a>.
* @param metadata Optional. Specifies a user-defined name-value pair associated with the blob. If no name-value pairs are specified, the operation will copy the metadata from the source blob or file to the destination blob. If one or more name-value pairs are specified, the destination blob is created with the specified metadata, and metadata is not copied from the source blob or file. Note that beginning with version 2009-09-19, metadata names must adhere to the naming rules for C# identifiers. See Naming and Referencing Containers, Blobs, and Metadata for more information.
* @param access Specifies whether data in the container may be accessed publicly and the level of access. Possible values include: 'container', 'blob'.
+ * @param defaultEncryptionScope Optional. Specifies the default encryption scope on the container. If not specified, encryption is performed with the root account encryption key. For more information, see Encryption at Rest for Azure Storage Services.
+ * @param denyEncryptionScopeOverride Optional. Specifies whether to deny encryption scope override provided in the request or not. If true, reject the request with encryption scope. If false, encryption is performed using encryption scope provided in the request. For more information, see Encryption at Rest for Azure Storage Services.
* @param requestId Provides a client-generated, opaque value with a 1 KB character limit that is recorded in the analytics logs when storage analytics logging is enabled.
* @param context The context to associate with this operation.
* @throws IllegalArgumentException thrown if parameters fail the validation.
* @return a Mono which performs the network request upon subscription.
*/
@ServiceMethod(returns = ReturnType.SINGLE)
- public Mono createWithRestResponseAsync(String containerName, Integer timeout, Map metadata, PublicAccessType access, String requestId, Context context) {
+ public Mono createWithRestResponseAsync(String containerName, Integer timeout, Map metadata, PublicAccessType access, String defaultEncryptionScope, Boolean denyEncryptionScopeOverride, String requestId, Context context) {
final String restype = "container";
- return service.create(containerName, this.client.getUrl(), timeout, metadata, access, this.client.getVersion(), requestId, restype, context);
+ return service.create(containerName, this.client.getUrl(), timeout, metadata, access, defaultEncryptionScope, denyEncryptionScopeOverride, this.client.getVersion(), requestId, restype, context);
}
/**
diff --git a/sdk/storage/azure-storage-blob/src/main/java/com/azure/storage/blob/implementation/DirectorysImpl.java b/sdk/storage/azure-storage-blob/src/main/java/com/azure/storage/blob/implementation/DirectorysImpl.java
new file mode 100644
index 0000000000000..1085a8ace9093
--- /dev/null
+++ b/sdk/storage/azure-storage-blob/src/main/java/com/azure/storage/blob/implementation/DirectorysImpl.java
@@ -0,0 +1,363 @@
+// Copyright (c) Microsoft Corporation. All rights reserved.
+// Licensed under the MIT License.
+// Code generated by Microsoft (R) AutoRest Code Generator.
+
+package com.azure.storage.blob.implementation;
+
+import com.azure.core.implementation.DateTimeRfc1123;
+import com.azure.core.implementation.RestProxy;
+import com.azure.core.implementation.annotation.Delete;
+import com.azure.core.implementation.annotation.ExpectedResponses;
+import com.azure.core.implementation.annotation.HeaderParam;
+import com.azure.core.implementation.annotation.Host;
+import com.azure.core.implementation.annotation.HostParam;
+import com.azure.core.implementation.annotation.PathParam;
+import com.azure.core.implementation.annotation.Put;
+import com.azure.core.implementation.annotation.QueryParam;
+import com.azure.core.implementation.annotation.ReturnType;
+import com.azure.core.implementation.annotation.ServiceInterface;
+import com.azure.core.implementation.annotation.ServiceMethod;
+import com.azure.core.implementation.annotation.UnexpectedResponseExceptionType;
+import com.azure.core.util.Context;
+import com.azure.storage.blob.models.DataLakeStorageErrorException;
+import com.azure.storage.blob.models.DirectoryHttpHeaders;
+import com.azure.storage.blob.models.DirectorysCreateResponse;
+import com.azure.storage.blob.models.DirectorysDeleteResponse;
+import com.azure.storage.blob.models.DirectorysRenameResponse;
+import com.azure.storage.blob.models.LeaseAccessConditions;
+import com.azure.storage.blob.models.ModifiedAccessConditions;
+import com.azure.storage.blob.models.PathRenameMode;
+import com.azure.storage.blob.models.SourceModifiedAccessConditions;
+import java.time.OffsetDateTime;
+import reactor.core.publisher.Mono;
+
+/**
+ * An instance of this class provides access to all the operations defined in
+ * Directorys.
+ */
+public final class DirectorysImpl {
+ /**
+ * The proxy service used to perform REST calls.
+ */
+ private DirectorysService service;
+
+ /**
+ * The service client containing this operation class.
+ */
+ private AzureBlobStorageImpl client;
+
+ /**
+ * Initializes an instance of DirectorysImpl.
+ *
+ * @param client the instance of the service client containing this operation class.
+ */
+ public DirectorysImpl(AzureBlobStorageImpl client) {
+ this.service = RestProxy.create(DirectorysService.class, client.getHttpPipeline());
+ this.client = client;
+ }
+
+ /**
+ * The interface defining all the services for AzureBlobStorageDirectorys
+ * to be used by the proxy service to perform REST calls.
+ */
+ @Host("{url}")
+ @ServiceInterface(name = "AzureBlobStorageDirectorys")
+ private interface DirectorysService {
+ @Put("{filesystem}/{path}")
+ @ExpectedResponses({201})
+ @UnexpectedResponseExceptionType(DataLakeStorageErrorException.class)
+ Mono create(@PathParam("filesystem") String filesystem, @PathParam("path") String path, @HostParam("url") String url, @QueryParam("timeout") Integer timeout, @HeaderParam("x-ms-properties") String directoryProperties, @HeaderParam("x-ms-permissions") String posixPermissions, @HeaderParam("x-ms-umask") String posixUmask, @HeaderParam("x-ms-version") String version, @HeaderParam("x-ms-client-request-id") String requestId, @QueryParam("resource") String resource, @HeaderParam("x-ms-cache-control") String cacheControl, @HeaderParam("x-ms-content-type") String contentType, @HeaderParam("x-ms-content-encoding") String contentEncoding, @HeaderParam("x-ms-content-language") String contentLanguage, @HeaderParam("x-ms-content-disposition") String contentDisposition, @HeaderParam("x-ms-lease-id") String leaseId, @HeaderParam("If-Modified-Since") DateTimeRfc1123 ifModifiedSince, @HeaderParam("If-Unmodified-Since") DateTimeRfc1123 ifUnmodifiedSince, @HeaderParam("If-Match") String ifMatch, @HeaderParam("If-None-Match") String ifNoneMatch, Context context);
+
+ @Put("{filesystem}/{path}")
+ @ExpectedResponses({201})
+ @UnexpectedResponseExceptionType(DataLakeStorageErrorException.class)
+ Mono rename(@PathParam("filesystem") String filesystem, @PathParam("path") String path, @HostParam("url") String url, @QueryParam("timeout") Integer timeout, @QueryParam("continuation") String marker, @QueryParam("mode") PathRenameMode pathRenameMode, @HeaderParam("x-ms-rename-source") String renameSource, @HeaderParam("x-ms-properties") String directoryProperties, @HeaderParam("x-ms-permissions") String posixPermissions, @HeaderParam("x-ms-umask") String posixUmask, @HeaderParam("x-ms-source-lease-id") String sourceLeaseId, @HeaderParam("x-ms-version") String version, @HeaderParam("x-ms-client-request-id") String requestId, @HeaderParam("x-ms-cache-control") String cacheControl, @HeaderParam("x-ms-content-type") String contentType, @HeaderParam("x-ms-content-encoding") String contentEncoding, @HeaderParam("x-ms-content-language") String contentLanguage, @HeaderParam("x-ms-content-disposition") String contentDisposition, @HeaderParam("x-ms-lease-id") String leaseId, @HeaderParam("If-Modified-Since") DateTimeRfc1123 ifModifiedSince, @HeaderParam("If-Unmodified-Since") DateTimeRfc1123 ifUnmodifiedSince, @HeaderParam("If-Match") String ifMatch, @HeaderParam("If-None-Match") String ifNoneMatch, @HeaderParam("x-ms-source-if-modified-since") DateTimeRfc1123 sourceIfModifiedSince, @HeaderParam("x-ms-source-if-unmodified-since") DateTimeRfc1123 sourceIfUnmodifiedSince, @HeaderParam("x-ms-source-if-match") String sourceIfMatch, @HeaderParam("x-ms-source-if-none-match") String sourceIfNoneMatch, Context context);
+
+ @Delete("{filesystem}/{path}")
+ @ExpectedResponses({200})
+ @UnexpectedResponseExceptionType(DataLakeStorageErrorException.class)
+ Mono delete(@PathParam("filesystem") String filesystem, @PathParam("path") String path, @HostParam("url") String url, @QueryParam("timeout") Integer timeout, @QueryParam("recursive") boolean recursiveDirectoryDelete, @QueryParam("continuation") String marker, @HeaderParam("x-ms-version") String version, @HeaderParam("x-ms-client-request-id") String requestId, @HeaderParam("x-ms-lease-id") String leaseId, @HeaderParam("If-Modified-Since") DateTimeRfc1123 ifModifiedSince, @HeaderParam("If-Unmodified-Since") DateTimeRfc1123 ifUnmodifiedSince, @HeaderParam("If-Match") String ifMatch, @HeaderParam("If-None-Match") String ifNoneMatch, Context context);
+ }
+
+ /**
+ * Create a directory. By default, the destination is overwritten and if the destination already exists and has a lease the lease is broken. This operation supports conditional HTTP requests. For more information, see [Specifying Conditional Headers for Blob Service Operations](https://docs.microsoft.com/en-us/rest/api/storageservices/specifying-conditional-headers-for-blob-service-operations). To fail if the destination already exists, use a conditional request with If-None-Match: "*".
+ *
+ * @param filesystem The filesystem name.
+ * @param path The namespace path to a file or directory.
+ * @param context The context to associate with this operation.
+ * @throws IllegalArgumentException thrown if parameters fail the validation.
+ * @return a Mono which performs the network request upon subscription.
+ */
+ @ServiceMethod(returns = ReturnType.SINGLE)
+ public Mono createWithRestResponseAsync(String filesystem, String path, Context context) {
+ final Integer timeout = null;
+ final String directoryProperties = null;
+ final String posixPermissions = null;
+ final String posixUmask = null;
+ final String requestId = null;
+ final String resource = "directory";
+ final String cacheControl = null;
+ final String contentType = null;
+ final String contentEncoding = null;
+ final String contentLanguage = null;
+ final String contentDisposition = null;
+ final String leaseId = null;
+ final String ifMatch = null;
+ final String ifNoneMatch = null;
+ DateTimeRfc1123 ifModifiedSinceConverted = null;
+ DateTimeRfc1123 ifUnmodifiedSinceConverted = null;
+ return service.create(filesystem, path, this.client.getUrl(), timeout, directoryProperties, posixPermissions, posixUmask, this.client.getVersion(), requestId, resource, cacheControl, contentType, contentEncoding, contentLanguage, contentDisposition, leaseId, ifModifiedSinceConverted, ifUnmodifiedSinceConverted, ifMatch, ifNoneMatch, context);
+ }
+
+ /**
+ * Create a directory. By default, the destination is overwritten and if the destination already exists and has a lease the lease is broken. This operation supports conditional HTTP requests. For more information, see [Specifying Conditional Headers for Blob Service Operations](https://docs.microsoft.com/en-us/rest/api/storageservices/specifying-conditional-headers-for-blob-service-operations). To fail if the destination already exists, use a conditional request with If-None-Match: "*".
+ *
+ * @param filesystem The filesystem name.
+ * @param path The namespace path to a file or directory.
+ * @param timeout The timeout parameter is expressed in seconds. For more information, see <a href="https://docs.microsoft.com/en-us/rest/api/storageservices/fileservices/setting-timeouts-for-blob-service-operations">Setting Timeouts for Blob Service Operations.</a>.
+ * @param directoryProperties Optional. User-defined properties to be stored with the file or directory, in the format of a comma-separated list of name and value pairs "n1=v1, n2=v2, ...", where each value is base64 encoded.
+ * @param posixPermissions Optional and only valid if Hierarchical Namespace is enabled for the account. Sets POSIX access permissions for the file owner, the file owning group, and others. Each class may be granted read, write, or execute permission. The sticky bit is also supported. Both symbolic (rwxrw-rw-) and 4-digit octal notation (e.g. 0766) are supported.
+ * @param posixUmask Only valid if Hierarchical Namespace is enabled for the account. This umask restricts permission settings for file and directory, and will only be applied when default Acl does not exist in parent directory. If the umask bit has set, it means that the corresponding permission will be disabled. Otherwise the corresponding permission will be determined by the permission. A 4-digit octal notation (e.g. 0022) is supported here. If no umask was specified, a default umask - 0027 will be used.
+ * @param requestId Provides a client-generated, opaque value with a 1 KB character limit that is recorded in the analytics logs when storage analytics logging is enabled.
+ * @param directoryHttpHeaders Additional parameters for the operation.
+ * @param leaseAccessConditions Additional parameters for the operation.
+ * @param modifiedAccessConditions Additional parameters for the operation.
+ * @param context The context to associate with this operation.
+ * @throws IllegalArgumentException thrown if parameters fail the validation.
+ * @return a Mono which performs the network request upon subscription.
+ */
+ @ServiceMethod(returns = ReturnType.SINGLE)
+ public Mono createWithRestResponseAsync(String filesystem, String path, Integer timeout, String directoryProperties, String posixPermissions, String posixUmask, String requestId, DirectoryHttpHeaders directoryHttpHeaders, LeaseAccessConditions leaseAccessConditions, ModifiedAccessConditions modifiedAccessConditions, Context context) {
+ final String resource = "directory";
+ String cacheControl = null;
+ if (directoryHttpHeaders != null) {
+ cacheControl = directoryHttpHeaders.cacheControl();
+ }
+ String contentType = null;
+ if (directoryHttpHeaders != null) {
+ contentType = directoryHttpHeaders.contentType();
+ }
+ String contentEncoding = null;
+ if (directoryHttpHeaders != null) {
+ contentEncoding = directoryHttpHeaders.contentEncoding();
+ }
+ String contentLanguage = null;
+ if (directoryHttpHeaders != null) {
+ contentLanguage = directoryHttpHeaders.contentLanguage();
+ }
+ String contentDisposition = null;
+ if (directoryHttpHeaders != null) {
+ contentDisposition = directoryHttpHeaders.contentDisposition();
+ }
+ String leaseId = null;
+ if (leaseAccessConditions != null) {
+ leaseId = leaseAccessConditions.leaseId();
+ }
+ OffsetDateTime ifModifiedSince = null;
+ if (modifiedAccessConditions != null) {
+ ifModifiedSince = modifiedAccessConditions.ifModifiedSince();
+ }
+ OffsetDateTime ifUnmodifiedSince = null;
+ if (modifiedAccessConditions != null) {
+ ifUnmodifiedSince = modifiedAccessConditions.ifUnmodifiedSince();
+ }
+ String ifMatch = null;
+ if (modifiedAccessConditions != null) {
+ ifMatch = modifiedAccessConditions.ifMatch();
+ }
+ String ifNoneMatch = null;
+ if (modifiedAccessConditions != null) {
+ ifNoneMatch = modifiedAccessConditions.ifNoneMatch();
+ }
+ DateTimeRfc1123 ifModifiedSinceConverted = ifModifiedSince == null ? null : new DateTimeRfc1123(ifModifiedSince);
+ DateTimeRfc1123 ifUnmodifiedSinceConverted = ifUnmodifiedSince == null ? null : new DateTimeRfc1123(ifUnmodifiedSince);
+ return service.create(filesystem, path, this.client.getUrl(), timeout, directoryProperties, posixPermissions, posixUmask, this.client.getVersion(), requestId, resource, cacheControl, contentType, contentEncoding, contentLanguage, contentDisposition, leaseId, ifModifiedSinceConverted, ifUnmodifiedSinceConverted, ifMatch, ifNoneMatch, context);
+ }
+
+ /**
+ * Rename a directory. By default, the destination is overwritten and if the destination already exists and has a lease the lease is broken. This operation supports conditional HTTP requests. For more information, see [Specifying Conditional Headers for Blob Service Operations](https://docs.microsoft.com/en-us/rest/api/storageservices/specifying-conditional-headers-for-blob-service-operations). To fail if the destination already exists, use a conditional request with If-None-Match: "*".
+ *
+ * @param filesystem The filesystem name.
+ * @param path The namespace path to a file or directory.
+ * @param renameSource The file or directory to be renamed. The value must have the following format: "/{filesysystem}/{path}". If "x-ms-properties" is specified, the properties will overwrite the existing properties; otherwise, the existing properties will be preserved.
+ * @param context The context to associate with this operation.
+ * @throws IllegalArgumentException thrown if parameters fail the validation.
+ * @return a Mono which performs the network request upon subscription.
+ */
+ @ServiceMethod(returns = ReturnType.SINGLE)
+ public Mono renameWithRestResponseAsync(String filesystem, String path, String renameSource, Context context) {
+ final Integer timeout = null;
+ final String marker = null;
+ final String directoryProperties = null;
+ final String posixPermissions = null;
+ final String posixUmask = null;
+ final String sourceLeaseId = null;
+ final String requestId = null;
+ final String cacheControl = null;
+ final String contentType = null;
+ final String contentEncoding = null;
+ final String contentLanguage = null;
+ final String contentDisposition = null;
+ final String leaseId = null;
+ final String ifMatch = null;
+ final String ifNoneMatch = null;
+ final String sourceIfMatch = null;
+ final String sourceIfNoneMatch = null;
+ DateTimeRfc1123 ifModifiedSinceConverted = null;
+ DateTimeRfc1123 ifUnmodifiedSinceConverted = null;
+ DateTimeRfc1123 sourceIfModifiedSinceConverted = null;
+ DateTimeRfc1123 sourceIfUnmodifiedSinceConverted = null;
+ return service.rename(filesystem, path, this.client.getUrl(), timeout, marker, this.client.getPathRenameMode(), renameSource, directoryProperties, posixPermissions, posixUmask, sourceLeaseId, this.client.getVersion(), requestId, cacheControl, contentType, contentEncoding, contentLanguage, contentDisposition, leaseId, ifModifiedSinceConverted, ifUnmodifiedSinceConverted, ifMatch, ifNoneMatch, sourceIfModifiedSinceConverted, sourceIfUnmodifiedSinceConverted, sourceIfMatch, sourceIfNoneMatch, context);
+ }
+
+ /**
+ * Rename a directory. By default, the destination is overwritten and if the destination already exists and has a lease the lease is broken. This operation supports conditional HTTP requests. For more information, see [Specifying Conditional Headers for Blob Service Operations](https://docs.microsoft.com/en-us/rest/api/storageservices/specifying-conditional-headers-for-blob-service-operations). To fail if the destination already exists, use a conditional request with If-None-Match: "*".
+ *
+ * @param filesystem The filesystem name.
+ * @param path The namespace path to a file or directory.
+ * @param renameSource The file or directory to be renamed. The value must have the following format: "/{filesysystem}/{path}". If "x-ms-properties" is specified, the properties will overwrite the existing properties; otherwise, the existing properties will be preserved.
+ * @param timeout The timeout parameter is expressed in seconds. For more information, see <a href="https://docs.microsoft.com/en-us/rest/api/storageservices/fileservices/setting-timeouts-for-blob-service-operations">Setting Timeouts for Blob Service Operations.</a>.
+ * @param marker When renaming a directory, the number of paths that are renamed with each invocation is limited. If the number of paths to be renamed exceeds this limit, a continuation token is returned in this response header. When a continuation token is returned in the response, it must be specified in a subsequent invocation of the rename operation to continue renaming the directory.
+ * @param directoryProperties Optional. User-defined properties to be stored with the file or directory, in the format of a comma-separated list of name and value pairs "n1=v1, n2=v2, ...", where each value is base64 encoded.
+ * @param posixPermissions Optional and only valid if Hierarchical Namespace is enabled for the account. Sets POSIX access permissions for the file owner, the file owning group, and others. Each class may be granted read, write, or execute permission. The sticky bit is also supported. Both symbolic (rwxrw-rw-) and 4-digit octal notation (e.g. 0766) are supported.
+ * @param posixUmask Only valid if Hierarchical Namespace is enabled for the account. This umask restricts permission settings for file and directory, and will only be applied when default Acl does not exist in parent directory. If the umask bit has set, it means that the corresponding permission will be disabled. Otherwise the corresponding permission will be determined by the permission. A 4-digit octal notation (e.g. 0022) is supported here. If no umask was specified, a default umask - 0027 will be used.
+ * @param sourceLeaseId A lease ID for the source path. If specified, the source path must have an active lease and the leaase ID must match.
+ * @param requestId Provides a client-generated, opaque value with a 1 KB character limit that is recorded in the analytics logs when storage analytics logging is enabled.
+ * @param directoryHttpHeaders Additional parameters for the operation.
+ * @param leaseAccessConditions Additional parameters for the operation.
+ * @param modifiedAccessConditions Additional parameters for the operation.
+ * @param sourceModifiedAccessConditions Additional parameters for the operation.
+ * @param context The context to associate with this operation.
+ * @throws IllegalArgumentException thrown if parameters fail the validation.
+ * @return a Mono which performs the network request upon subscription.
+ */
+ @ServiceMethod(returns = ReturnType.SINGLE)
+ public Mono renameWithRestResponseAsync(String filesystem, String path, String renameSource, Integer timeout, String marker, String directoryProperties, String posixPermissions, String posixUmask, String sourceLeaseId, String requestId, DirectoryHttpHeaders directoryHttpHeaders, LeaseAccessConditions leaseAccessConditions, ModifiedAccessConditions modifiedAccessConditions, SourceModifiedAccessConditions sourceModifiedAccessConditions, Context context) {
+ String cacheControl = null;
+ if (directoryHttpHeaders != null) {
+ cacheControl = directoryHttpHeaders.cacheControl();
+ }
+ String contentType = null;
+ if (directoryHttpHeaders != null) {
+ contentType = directoryHttpHeaders.contentType();
+ }
+ String contentEncoding = null;
+ if (directoryHttpHeaders != null) {
+ contentEncoding = directoryHttpHeaders.contentEncoding();
+ }
+ String contentLanguage = null;
+ if (directoryHttpHeaders != null) {
+ contentLanguage = directoryHttpHeaders.contentLanguage();
+ }
+ String contentDisposition = null;
+ if (directoryHttpHeaders != null) {
+ contentDisposition = directoryHttpHeaders.contentDisposition();
+ }
+ String leaseId = null;
+ if (leaseAccessConditions != null) {
+ leaseId = leaseAccessConditions.leaseId();
+ }
+ OffsetDateTime ifModifiedSince = null;
+ if (modifiedAccessConditions != null) {
+ ifModifiedSince = modifiedAccessConditions.ifModifiedSince();
+ }
+ OffsetDateTime ifUnmodifiedSince = null;
+ if (modifiedAccessConditions != null) {
+ ifUnmodifiedSince = modifiedAccessConditions.ifUnmodifiedSince();
+ }
+ String ifMatch = null;
+ if (modifiedAccessConditions != null) {
+ ifMatch = modifiedAccessConditions.ifMatch();
+ }
+ String ifNoneMatch = null;
+ if (modifiedAccessConditions != null) {
+ ifNoneMatch = modifiedAccessConditions.ifNoneMatch();
+ }
+ OffsetDateTime sourceIfModifiedSince = null;
+ if (sourceModifiedAccessConditions != null) {
+ sourceIfModifiedSince = sourceModifiedAccessConditions.sourceIfModifiedSince();
+ }
+ OffsetDateTime sourceIfUnmodifiedSince = null;
+ if (sourceModifiedAccessConditions != null) {
+ sourceIfUnmodifiedSince = sourceModifiedAccessConditions.sourceIfUnmodifiedSince();
+ }
+ String sourceIfMatch = null;
+ if (sourceModifiedAccessConditions != null) {
+ sourceIfMatch = sourceModifiedAccessConditions.sourceIfMatch();
+ }
+ String sourceIfNoneMatch = null;
+ if (sourceModifiedAccessConditions != null) {
+ sourceIfNoneMatch = sourceModifiedAccessConditions.sourceIfNoneMatch();
+ }
+ DateTimeRfc1123 ifModifiedSinceConverted = ifModifiedSince == null ? null : new DateTimeRfc1123(ifModifiedSince);
+ DateTimeRfc1123 ifUnmodifiedSinceConverted = ifUnmodifiedSince == null ? null : new DateTimeRfc1123(ifUnmodifiedSince);
+ DateTimeRfc1123 sourceIfModifiedSinceConverted = sourceIfModifiedSince == null ? null : new DateTimeRfc1123(sourceIfModifiedSince);
+ DateTimeRfc1123 sourceIfUnmodifiedSinceConverted = sourceIfUnmodifiedSince == null ? null : new DateTimeRfc1123(sourceIfUnmodifiedSince);
+ return service.rename(filesystem, path, this.client.getUrl(), timeout, marker, this.client.getPathRenameMode(), renameSource, directoryProperties, posixPermissions, posixUmask, sourceLeaseId, this.client.getVersion(), requestId, cacheControl, contentType, contentEncoding, contentLanguage, contentDisposition, leaseId, ifModifiedSinceConverted, ifUnmodifiedSinceConverted, ifMatch, ifNoneMatch, sourceIfModifiedSinceConverted, sourceIfUnmodifiedSinceConverted, sourceIfMatch, sourceIfNoneMatch, context);
+ }
+
+ /**
+ * Deletes the directory.
+ *
+ * @param filesystem The filesystem name.
+ * @param path The namespace path to a file or directory.
+ * @param recursiveDirectoryDelete If "true", all paths beneath the directory will be deleted. If "false" and the directory is non-empty, an error occurs.
+ * @param context The context to associate with this operation.
+ * @throws IllegalArgumentException thrown if parameters fail the validation.
+ * @return a Mono which performs the network request upon subscription.
+ */
+ @ServiceMethod(returns = ReturnType.SINGLE)
+ public Mono deleteWithRestResponseAsync(String filesystem, String path, boolean recursiveDirectoryDelete, Context context) {
+ final Integer timeout = null;
+ final String marker = null;
+ final String requestId = null;
+ final String leaseId = null;
+ final String ifMatch = null;
+ final String ifNoneMatch = null;
+ DateTimeRfc1123 ifModifiedSinceConverted = null;
+ DateTimeRfc1123 ifUnmodifiedSinceConverted = null;
+ return service.delete(filesystem, path, this.client.getUrl(), timeout, recursiveDirectoryDelete, marker, this.client.getVersion(), requestId, leaseId, ifModifiedSinceConverted, ifUnmodifiedSinceConverted, ifMatch, ifNoneMatch, context);
+ }
+
+ /**
+ * Deletes the directory.
+ *
+ * @param filesystem The filesystem name.
+ * @param path The namespace path to a file or directory.
+ * @param recursiveDirectoryDelete If "true", all paths beneath the directory will be deleted. If "false" and the directory is non-empty, an error occurs.
+ * @param timeout The timeout parameter is expressed in seconds. For more information, see <a href="https://docs.microsoft.com/en-us/rest/api/storageservices/fileservices/setting-timeouts-for-blob-service-operations">Setting Timeouts for Blob Service Operations.</a>.
+ * @param marker When renaming a directory, the number of paths that are renamed with each invocation is limited. If the number of paths to be renamed exceeds this limit, a continuation token is returned in this response header. When a continuation token is returned in the response, it must be specified in a subsequent invocation of the rename operation to continue renaming the directory.
+ * @param requestId Provides a client-generated, opaque value with a 1 KB character limit that is recorded in the analytics logs when storage analytics logging is enabled.
+ * @param leaseAccessConditions Additional parameters for the operation.
+ * @param modifiedAccessConditions Additional parameters for the operation.
+ * @param context The context to associate with this operation.
+ * @throws IllegalArgumentException thrown if parameters fail the validation.
+ * @return a Mono which performs the network request upon subscription.
+ */
+ @ServiceMethod(returns = ReturnType.SINGLE)
+ public Mono deleteWithRestResponseAsync(String filesystem, String path, boolean recursiveDirectoryDelete, Integer timeout, String marker, String requestId, LeaseAccessConditions leaseAccessConditions, ModifiedAccessConditions modifiedAccessConditions, Context context) {
+ String leaseId = null;
+ if (leaseAccessConditions != null) {
+ leaseId = leaseAccessConditions.leaseId();
+ }
+ OffsetDateTime ifModifiedSince = null;
+ if (modifiedAccessConditions != null) {
+ ifModifiedSince = modifiedAccessConditions.ifModifiedSince();
+ }
+ OffsetDateTime ifUnmodifiedSince = null;
+ if (modifiedAccessConditions != null) {
+ ifUnmodifiedSince = modifiedAccessConditions.ifUnmodifiedSince();
+ }
+ String ifMatch = null;
+ if (modifiedAccessConditions != null) {
+ ifMatch = modifiedAccessConditions.ifMatch();
+ }
+ String ifNoneMatch = null;
+ if (modifiedAccessConditions != null) {
+ ifNoneMatch = modifiedAccessConditions.ifNoneMatch();
+ }
+ DateTimeRfc1123 ifModifiedSinceConverted = ifModifiedSince == null ? null : new DateTimeRfc1123(ifModifiedSince);
+ DateTimeRfc1123 ifUnmodifiedSinceConverted = ifUnmodifiedSince == null ? null : new DateTimeRfc1123(ifUnmodifiedSince);
+ return service.delete(filesystem, path, this.client.getUrl(), timeout, recursiveDirectoryDelete, marker, this.client.getVersion(), requestId, leaseId, ifModifiedSinceConverted, ifUnmodifiedSinceConverted, ifMatch, ifNoneMatch, context);
+ }
+}
diff --git a/sdk/storage/azure-storage-blob/src/main/java/com/azure/storage/blob/implementation/PageBlobsImpl.java b/sdk/storage/azure-storage-blob/src/main/java/com/azure/storage/blob/implementation/PageBlobsImpl.java
index 97dd44b22bc54..2b171b31339e5 100644
--- a/sdk/storage/azure-storage-blob/src/main/java/com/azure/storage/blob/implementation/PageBlobsImpl.java
+++ b/sdk/storage/azure-storage-blob/src/main/java/com/azure/storage/blob/implementation/PageBlobsImpl.java
@@ -22,6 +22,7 @@
import com.azure.core.implementation.util.Base64Util;
import com.azure.core.util.Context;
import com.azure.storage.blob.models.BlobHTTPHeaders;
+import com.azure.storage.blob.models.CustomerProvidedKeyInfo;
import com.azure.storage.blob.models.EncryptionAlgorithmType;
import com.azure.storage.blob.models.LeaseAccessConditions;
import com.azure.storage.blob.models.ModifiedAccessConditions;
@@ -80,12 +81,12 @@ private interface PageBlobsService {
@Put("{containerName}/{blob}")
@ExpectedResponses({201})
@UnexpectedResponseExceptionType(StorageErrorException.class)
- Mono create(@PathParam("containerName") String containerName, @PathParam("blob") String blob, @HostParam("url") String url, @QueryParam("timeout") Integer timeout, @HeaderParam("Content-Length") long contentLength, @HeaderParam("x-ms-meta-") Map metadata, @QueryParam("x-ms-encryption-key") String encryptionKey, @QueryParam("x-ms-encryption-key-sha256") String encryptionKeySha256, @QueryParam("x-ms-encryption-algorithm") EncryptionAlgorithmType encryptionAlgorithm, @HeaderParam("x-ms-blob-content-length") long blobContentLength, @HeaderParam("x-ms-blob-sequence-number") Long blobSequenceNumber, @HeaderParam("x-ms-version") String version, @HeaderParam("x-ms-client-request-id") String requestId, @HeaderParam("x-ms-blob-type") String blobType, @HeaderParam("x-ms-blob-content-type") String blobContentType, @HeaderParam("x-ms-blob-content-encoding") String blobContentEncoding, @HeaderParam("x-ms-blob-content-language") String blobContentLanguage, @HeaderParam("x-ms-blob-content-md5") String blobContentMD5, @HeaderParam("x-ms-blob-cache-control") String blobCacheControl, @HeaderParam("x-ms-blob-content-disposition") String blobContentDisposition, @HeaderParam("x-ms-lease-id") String leaseId, @HeaderParam("If-Modified-Since") DateTimeRfc1123 ifModifiedSince, @HeaderParam("If-Unmodified-Since") DateTimeRfc1123 ifUnmodifiedSince, @HeaderParam("If-Match") String ifMatch, @HeaderParam("If-None-Match") String ifNoneMatch, Context context);
+ Mono create(@PathParam("containerName") String containerName, @PathParam("blob") String blob, @HostParam("url") String url, @QueryParam("timeout") Integer timeout, @HeaderParam("Content-Length") long contentLength, @HeaderParam("x-ms-meta-") Map metadata, @HeaderParam("x-ms-tags") String tags, @QueryParam("x-ms-encryption-key") String xMsEncryptionKey, @QueryParam("x-ms-encryption-key-sha256") String xMsEncryptionKeySha256, @QueryParam("x-ms-encryption-algorithm") EncryptionAlgorithmType xMsEncryptionAlgorithm, @HeaderParam("x-ms-blob-content-length") long blobContentLength, @HeaderParam("x-ms-blob-sequence-number") Long blobSequenceNumber, @HeaderParam("x-ms-version") String version, @HeaderParam("x-ms-client-request-id") String requestId, @HeaderParam("x-ms-blob-type") String blobType, @HeaderParam("x-ms-blob-content-type") String blobContentType, @HeaderParam("x-ms-blob-content-encoding") String blobContentEncoding, @HeaderParam("x-ms-blob-content-language") String blobContentLanguage, @HeaderParam("x-ms-blob-content-md5") String blobContentMD5, @HeaderParam("x-ms-blob-cache-control") String blobCacheControl, @HeaderParam("x-ms-blob-content-disposition") String blobContentDisposition, @HeaderParam("x-ms-lease-id") String leaseId, @QueryParam("x-ms-encryption-scope") String encryptionScope, @HeaderParam("If-Modified-Since") DateTimeRfc1123 ifModifiedSince, @HeaderParam("If-Unmodified-Since") DateTimeRfc1123 ifUnmodifiedSince, @HeaderParam("If-Match") String ifMatch, @HeaderParam("If-None-Match") String ifNoneMatch, Context context);
@Put("{containerName}/{blob}")
@ExpectedResponses({201})
@UnexpectedResponseExceptionType(StorageErrorException.class)
- Mono uploadPages(@PathParam("containerName") String containerName, @PathParam("blob") String blob, @HostParam("url") String url, @BodyParam("application/octet-stream") Flux body, @HeaderParam("Content-Length") long contentLength, @HeaderParam("Content-MD5") String transactionalContentMD5, @QueryParam("timeout") Integer timeout, @HeaderParam("x-ms-range") String range, @QueryParam("x-ms-encryption-key") String encryptionKey, @QueryParam("x-ms-encryption-key-sha256") String encryptionKeySha256, @QueryParam("x-ms-encryption-algorithm") EncryptionAlgorithmType encryptionAlgorithm, @HeaderParam("x-ms-version") String version, @HeaderParam("x-ms-client-request-id") String requestId, @QueryParam("comp") String comp, @HeaderParam("x-ms-page-write") String pageWrite, @HeaderParam("x-ms-lease-id") String leaseId, @HeaderParam("x-ms-if-sequence-number-le") Long ifSequenceNumberLessThanOrEqualTo, @HeaderParam("x-ms-if-sequence-number-lt") Long ifSequenceNumberLessThan, @HeaderParam("x-ms-if-sequence-number-eq") Long ifSequenceNumberEqualTo, @HeaderParam("If-Modified-Since") DateTimeRfc1123 ifModifiedSince, @HeaderParam("If-Unmodified-Since") DateTimeRfc1123 ifUnmodifiedSince, @HeaderParam("If-Match") String ifMatch, @HeaderParam("If-None-Match") String ifNoneMatch, Context context);
+ Mono uploadPages(@PathParam("containerName") String containerName, @PathParam("blob") String blob, @HostParam("url") String url, @BodyParam("application/octet-stream") Flux body, @HeaderParam("Content-Length") long contentLength, @HeaderParam("Content-MD5") String transactionalContentMD5, @HeaderParam("x-ms-content-crc64") String transactionalContentCrc64, @QueryParam("timeout") Integer timeout, @HeaderParam("x-ms-range") String range, @QueryParam("x-ms-encryption-key") String xMsEncryptionKey, @QueryParam("x-ms-encryption-key-sha256") String xMsEncryptionKeySha256, @QueryParam("x-ms-encryption-algorithm") EncryptionAlgorithmType xMsEncryptionAlgorithm, @HeaderParam("x-ms-version") String version, @HeaderParam("x-ms-client-request-id") String requestId, @QueryParam("comp") String comp, @HeaderParam("x-ms-page-write") String pageWrite, @HeaderParam("x-ms-lease-id") String leaseId, @QueryParam("x-ms-encryption-scope") String encryptionScope, @HeaderParam("x-ms-if-sequence-number-le") Long ifSequenceNumberLessThanOrEqualTo, @HeaderParam("x-ms-if-sequence-number-lt") Long ifSequenceNumberLessThan, @HeaderParam("x-ms-if-sequence-number-eq") Long ifSequenceNumberEqualTo, @HeaderParam("If-Modified-Since") DateTimeRfc1123 ifModifiedSince, @HeaderParam("If-Unmodified-Since") DateTimeRfc1123 ifUnmodifiedSince, @HeaderParam("If-Match") String ifMatch, @HeaderParam("If-None-Match") String ifNoneMatch, Context context);
@Put("{containerName}/{blob}")
@ExpectedResponses({201})
@@ -95,7 +96,7 @@ private interface PageBlobsService {
@Put("{containerName}/{blob}")
@ExpectedResponses({201})
@UnexpectedResponseExceptionType(StorageErrorException.class)
- Mono uploadPagesFromURL(@PathParam("containerName") String containerName, @PathParam("blob") String blob, @HostParam("url") String url, @HeaderParam("x-ms-copy-source") URL copySource, @HeaderParam("x-ms-source-range") String sourceRange, @HeaderParam("x-ms-source-content-md5") String sourceContentMD5, @HeaderParam("Content-Length") long contentLength, @QueryParam("timeout") Integer timeout, @HeaderParam("x-ms-range") String range, @HeaderParam("x-ms-version") String version, @HeaderParam("x-ms-client-request-id") String requestId, @QueryParam("comp") String comp, @HeaderParam("x-ms-page-write") String pageWrite, @HeaderParam("x-ms-lease-id") String leaseId, @HeaderParam("x-ms-if-sequence-number-le") Long ifSequenceNumberLessThanOrEqualTo, @HeaderParam("x-ms-if-sequence-number-lt") Long ifSequenceNumberLessThan, @HeaderParam("x-ms-if-sequence-number-eq") Long ifSequenceNumberEqualTo, @HeaderParam("If-Modified-Since") DateTimeRfc1123 ifModifiedSince, @HeaderParam("If-Unmodified-Since") DateTimeRfc1123 ifUnmodifiedSince, @HeaderParam("If-Match") String ifMatch, @HeaderParam("If-None-Match") String ifNoneMatch, @HeaderParam("x-ms-source-if-modified-since") DateTimeRfc1123 sourceIfModifiedSince, @HeaderParam("x-ms-source-if-unmodified-since") DateTimeRfc1123 sourceIfUnmodifiedSince, @HeaderParam("x-ms-source-if-match") String sourceIfMatch, @HeaderParam("x-ms-source-if-none-match") String sourceIfNoneMatch, Context context);
+ Mono uploadPagesFromURL(@PathParam("containerName") String containerName, @PathParam("blob") String blob, @HostParam("url") String url, @HeaderParam("x-ms-copy-source") URL copySource, @HeaderParam("x-ms-source-range") String sourceRange, @HeaderParam("x-ms-source-content-md5") String sourceContentMD5, @HeaderParam("x-ms-source-content-crc64") String sourceContentcrc64, @HeaderParam("Content-Length") long contentLength, @QueryParam("timeout") Integer timeout, @HeaderParam("x-ms-range") String range, @HeaderParam("x-ms-version") String version, @HeaderParam("x-ms-client-request-id") String requestId, @QueryParam("comp") String comp, @HeaderParam("x-ms-page-write") String pageWrite, @HeaderParam("x-ms-lease-id") String leaseId, @HeaderParam("x-ms-if-sequence-number-le") Long ifSequenceNumberLessThanOrEqualTo, @HeaderParam("x-ms-if-sequence-number-lt") Long ifSequenceNumberLessThan, @HeaderParam("x-ms-if-sequence-number-eq") Long ifSequenceNumberEqualTo, @HeaderParam("If-Modified-Since") DateTimeRfc1123 ifModifiedSince, @HeaderParam("If-Unmodified-Since") DateTimeRfc1123 ifUnmodifiedSince, @HeaderParam("If-Match") String ifMatch, @HeaderParam("If-None-Match") String ifNoneMatch, @HeaderParam("x-ms-source-if-modified-since") DateTimeRfc1123 sourceIfModifiedSince, @HeaderParam("x-ms-source-if-unmodified-since") DateTimeRfc1123 sourceIfUnmodifiedSince, @HeaderParam("x-ms-source-if-match") String sourceIfMatch, @HeaderParam("x-ms-source-if-none-match") String sourceIfNoneMatch, Context context);
@Get("{containerName}/{blob}")
@ExpectedResponses({200})
@@ -138,9 +139,10 @@ private interface PageBlobsService {
public Mono createWithRestResponseAsync(String containerName, String blob, long contentLength, long blobContentLength, Context context) {
final Integer timeout = null;
final Map metadata = null;
- final String encryptionKey = null;
- final String encryptionKeySha256 = null;
- final EncryptionAlgorithmType encryptionAlgorithm = null;
+ final String tags = null;
+ final String xMsEncryptionKey = null;
+ final String xMsEncryptionKeySha256 = null;
+ final EncryptionAlgorithmType xMsEncryptionAlgorithm = null;
final Long blobSequenceNumber = 0L;
final String requestId = null;
final String blobType = "PageBlob";
@@ -150,12 +152,13 @@ public Mono createWithRestResponseAsync(String containe
final String blobCacheControl = null;
final String blobContentDisposition = null;
final String leaseId = null;
+ final String encryptionScope = null;
final String ifMatch = null;
final String ifNoneMatch = null;
String blobContentMD5Converted = null;
DateTimeRfc1123 ifModifiedSinceConverted = null;
DateTimeRfc1123 ifUnmodifiedSinceConverted = null;
- return service.create(containerName, blob, this.client.getUrl(), timeout, contentLength, metadata, encryptionKey, encryptionKeySha256, encryptionAlgorithm, blobContentLength, blobSequenceNumber, this.client.getVersion(), requestId, blobType, blobContentType, blobContentEncoding, blobContentLanguage, blobContentMD5Converted, blobCacheControl, blobContentDisposition, leaseId, ifModifiedSinceConverted, ifUnmodifiedSinceConverted, ifMatch, ifNoneMatch, context);
+ return service.create(containerName, blob, this.client.getUrl(), timeout, contentLength, metadata, tags, xMsEncryptionKey, xMsEncryptionKeySha256, xMsEncryptionAlgorithm, blobContentLength, blobSequenceNumber, this.client.getVersion(), requestId, blobType, blobContentType, blobContentEncoding, blobContentLanguage, blobContentMD5Converted, blobCacheControl, blobContentDisposition, leaseId, encryptionScope, ifModifiedSinceConverted, ifUnmodifiedSinceConverted, ifMatch, ifNoneMatch, context);
}
/**
@@ -167,20 +170,22 @@ public Mono createWithRestResponseAsync(String containe
* @param blobContentLength This header specifies the maximum size for the page blob, up to 1 TB. The page blob size must be aligned to a 512-byte boundary.
* @param timeout The timeout parameter is expressed in seconds. For more information, see <a href="https://docs.microsoft.com/en-us/rest/api/storageservices/fileservices/setting-timeouts-for-blob-service-operations">Setting Timeouts for Blob Service Operations.</a>.
* @param metadata Optional. Specifies a user-defined name-value pair associated with the blob. If no name-value pairs are specified, the operation will copy the metadata from the source blob or file to the destination blob. If one or more name-value pairs are specified, the destination blob is created with the specified metadata, and metadata is not copied from the source blob or file. Note that beginning with version 2009-09-19, metadata names must adhere to the naming rules for C# identifiers. See Naming and Referencing Containers, Blobs, and Metadata for more information.
- * @param encryptionKey Optional. Specifies the encryption key to use to encrypt the data provided in the request. If not specified, encryption is performed with the root account encryption key. For more information, see Encryption at Rest for Azure Storage Services.
- * @param encryptionKeySha256 The SHA-256 hash of the provided encryption key. Must be provided if the x-ms-encryption-key header is provided.
- * @param encryptionAlgorithm The algorithm used to produce the encryption key hash. Currently, the only accepted value is "AES256". Must be provided if the x-ms-encryption-key header is provided. Possible values include: 'AES256'.
+ * @param tags Optional. A URL encoded query param string which specifies the tags to be created with the Blob object. e.g. TagName1=TagValue1&TagName2=TagValue2. The x-ms-tags header may contain up to 2kb of tags.
+ * @param xMsEncryptionKey Optional. Specifies the encryption key to use to encrypt the data provided in the request. If not specified, encryption is performed with the root account encryption key. For more information, see Encryption at Rest for Azure Storage Services.
+ * @param xMsEncryptionKeySha256 The SHA-256 hash of the provided encryption key. Must be provided if the x-ms-encryption-key header is provided.
+ * @param xMsEncryptionAlgorithm The algorithm used to produce the encryption key hash. Currently, the only accepted value is "AES256". Must be provided if the x-ms-encryption-key header is provided. Possible values include: 'AES256'.
* @param blobSequenceNumber Set for page blobs only. The sequence number is a user-controlled value that you can use to track requests. The value of the sequence number must be between 0 and 2^63 - 1.
* @param requestId Provides a client-generated, opaque value with a 1 KB character limit that is recorded in the analytics logs when storage analytics logging is enabled.
* @param blobHTTPHeaders Additional parameters for the operation.
* @param leaseAccessConditions Additional parameters for the operation.
+ * @param customerProvidedKeyInfo Additional parameters for the operation.
* @param modifiedAccessConditions Additional parameters for the operation.
* @param context The context to associate with this operation.
* @throws IllegalArgumentException thrown if parameters fail the validation.
* @return a Mono which performs the network request upon subscription.
*/
@ServiceMethod(returns = ReturnType.SINGLE)
- public Mono createWithRestResponseAsync(String containerName, String blob, long contentLength, long blobContentLength, Integer timeout, Map metadata, String encryptionKey, String encryptionKeySha256, EncryptionAlgorithmType encryptionAlgorithm, Long blobSequenceNumber, String requestId, BlobHTTPHeaders blobHTTPHeaders, LeaseAccessConditions leaseAccessConditions, ModifiedAccessConditions modifiedAccessConditions, Context context) {
+ public Mono createWithRestResponseAsync(String containerName, String blob, long contentLength, long blobContentLength, Integer timeout, Map metadata, String tags, String xMsEncryptionKey, String xMsEncryptionKeySha256, EncryptionAlgorithmType xMsEncryptionAlgorithm, Long blobSequenceNumber, String requestId, BlobHTTPHeaders blobHTTPHeaders, LeaseAccessConditions leaseAccessConditions, CustomerProvidedKeyInfo customerProvidedKeyInfo, ModifiedAccessConditions modifiedAccessConditions, Context context) {
final String blobType = "PageBlob";
String blobContentType = null;
if (blobHTTPHeaders != null) {
@@ -210,6 +215,10 @@ public Mono createWithRestResponseAsync(String containe
if (leaseAccessConditions != null) {
leaseId = leaseAccessConditions.leaseId();
}
+ String encryptionScope = null;
+ if (customerProvidedKeyInfo != null) {
+ encryptionScope = customerProvidedKeyInfo.encryptionScope();
+ }
OffsetDateTime ifModifiedSince = null;
if (modifiedAccessConditions != null) {
ifModifiedSince = modifiedAccessConditions.ifModifiedSince();
@@ -229,7 +238,7 @@ public Mono createWithRestResponseAsync(String containe
String blobContentMD5Converted = Base64Util.encodeToString(blobContentMD5);
DateTimeRfc1123 ifModifiedSinceConverted = ifModifiedSince == null ? null : new DateTimeRfc1123(ifModifiedSince);
DateTimeRfc1123 ifUnmodifiedSinceConverted = ifUnmodifiedSince == null ? null : new DateTimeRfc1123(ifUnmodifiedSince);
- return service.create(containerName, blob, this.client.getUrl(), timeout, contentLength, metadata, encryptionKey, encryptionKeySha256, encryptionAlgorithm, blobContentLength, blobSequenceNumber, this.client.getVersion(), requestId, blobType, blobContentType, blobContentEncoding, blobContentLanguage, blobContentMD5Converted, blobCacheControl, blobContentDisposition, leaseId, ifModifiedSinceConverted, ifUnmodifiedSinceConverted, ifMatch, ifNoneMatch, context);
+ return service.create(containerName, blob, this.client.getUrl(), timeout, contentLength, metadata, tags, xMsEncryptionKey, xMsEncryptionKeySha256, xMsEncryptionAlgorithm, blobContentLength, blobSequenceNumber, this.client.getVersion(), requestId, blobType, blobContentType, blobContentEncoding, blobContentLanguage, blobContentMD5Converted, blobCacheControl, blobContentDisposition, leaseId, encryptionScope, ifModifiedSinceConverted, ifUnmodifiedSinceConverted, ifMatch, ifNoneMatch, context);
}
/**
@@ -247,22 +256,24 @@ public Mono