You are writing a .NET application to update the custom metadata of an Azure Blob Storage blob. The blob currently has an active exclusive-write lease.
Which of the following is required to successfully update the blob's metadata?
- APrefix the metadata keys with `x-ms-meta-` inside the SDK's metadata dictionary.
- BSubmit the update without a lease ID, as leases only protect the blob's binary content from deletion.
- Provide the active lease ID in the request conditions.Cevap
- DUse a long-lived account-level SAS token with full administrative permissions to bypass the lease.
Cevap
Providing the active lease ID in the request conditions is required to update the metadata of a leased blob.
Updating metadata is a write operation. When a blob is leased, any write operation must include the active lease ID. Passing this ID in the request conditions allows the storage service to verify ownership of the lock and permit the metadata change.
Adım Adım Çözüm
Anahtar Kavram
Writing or modifying a leased blob's properties or metadata requires specifying the active lease ID in the request.