diff --git a/sdk/storage/azure-storage-files-datalake/CHANGELOG.md b/sdk/storage/azure-storage-files-datalake/CHANGELOG.md index 94429815d..f1e7735c9 100644 --- a/sdk/storage/azure-storage-files-datalake/CHANGELOG.md +++ b/sdk/storage/azure-storage-files-datalake/CHANGELOG.md @@ -6,6 +6,10 @@ - Renamed `ContentLength` in `FlushFileResult` to `FileSize`. +### Other Changes and Improvements + +- Removed `IfUnmodifiedSince` from access conditions of setting filesystem metadata operation. + ## 12.0.0-beta.11 (2021-05-19) ### New Features diff --git a/sdk/storage/azure-storage-files-datalake/inc/azure/storage/files/datalake/datalake_options.hpp b/sdk/storage/azure-storage-files-datalake/inc/azure/storage/files/datalake/datalake_options.hpp index 6ab580c5e..0af991b87 100644 --- a/sdk/storage/azure-storage-files-datalake/inc/azure/storage/files/datalake/datalake_options.hpp +++ b/sdk/storage/azure-storage-files-datalake/inc/azure/storage/files/datalake/datalake_options.hpp @@ -141,7 +141,14 @@ namespace Azure { namespace Storage { namespace Files { namespace DataLake { /** * Specify the access condition for the file system. */ - FileSystemAccessConditions AccessConditions; + struct : public LeaseAccessConditions + { + /** + * @brief Specify this header to perform the operation only if the resource has been + * modified since the specified time. This timestamp will be truncated to second. + */ + Azure::Nullable IfModifiedSince; + } AccessConditions; }; /** diff --git a/sdk/storage/azure-storage-files-datalake/src/datalake_file_system_client.cpp b/sdk/storage/azure-storage-files-datalake/src/datalake_file_system_client.cpp index b9737919a..0d360a678 100644 --- a/sdk/storage/azure-storage-files-datalake/src/datalake_file_system_client.cpp +++ b/sdk/storage/azure-storage-files-datalake/src/datalake_file_system_client.cpp @@ -251,9 +251,6 @@ namespace Azure { namespace Storage { namespace Files { namespace DataLake { { Blobs::SetBlobContainerMetadataOptions blobOptions; blobOptions.AccessConditions.IfModifiedSince = options.AccessConditions.IfModifiedSince; - AZURE_ASSERT_MSG( - !options.AccessConditions.IfUnmodifiedSince.HasValue(), - "This operation doesn't support If-Unmodified-Since condition"); auto result = m_blobContainerClient.SetMetadata(std::move(metadata), blobOptions, context); Models::SetFileSystemMetadataResult ret;