Skip to content

Conversation

vincenttran-msft
Copy link
Member

@vincenttran-msft vincenttran-msft commented Jun 26, 2025

.tsp: Azure/azure-rest-api-specs#35564

Leasing Operations

  • Added initial introduction of lease APIs to BlobClient and BlobContainerClient
  • This includes: acquire_lease, break_lease, change_lease, release_lease, and renew_lease

BlobClient Lease Operations:
acquire_lease

  • ̶d̶a̶t̶e̶
  • last_modified
  • etag
  • lease_id

break_lease

  • d̶a̶t̶e̶
  • last_modified
  • etag
  • lease_time

change_lease

  • d̶a̶t̶e̶
  • last_modified
  • etag
  • lease_id

release_lease

  • d̶a̶t̶e̶
  • last_modified
  • etag

renew_lease

  • ̶d̶a̶t̶e̶
  • last_modified
  • etag
  • lease_id

BlobContainerClient Lease Operations:
acquire_lease

  • ̶d̶a̶t̶e̶
  • last_modified
  • etag
  • lease_id

break_lease

  • d̶a̶t̶e̶
  • last_modified
  • etag
  • ̶l̶e̶a̶s̶e̶_̶i̶d̶
  • lease_time

change_lease

  • d̶a̶t̶e̶
  • last_modified
  • etag
  • lease_id

release_lease

  • d̶a̶t̶e̶
  • last_modified
  • etag

renew_lease

  • ̶d̶a̶t̶e̶
  • last_modified
  • etag
  • lease_id

AppendBlobClient APIs

  • Finishes out the rest of the APIs for AppendBlobClient to make it more usable beyond initially introduced create API
  • This includes: append_block, append_block_from_url, and seal

append_block

  • content_md5
  • d̶a̶t̶e̶
  • last_modified
  • etag
  • blob_append_offset
  • blob_commited_block_count
  • content_crc64
  • encryption_key_sha256
  • encryption_scope
  • is_server_encrypted

append_block_from_url

  • content_md5
  • d̶a̶t̶e̶
  • last_modified
  • etag
  • blob_append_offset
  • blob_commited_block_count
  • content_crc64
  • encryption_key_sha256
  • encryption_scope
  • is_server_encrypted

seal

  • d̶a̶t̶e̶
  • last_modified
  • etag
  • is_sealed

@github-actions github-actions bot added the Storage Storage Service (Queues, Blobs, Files) label Jun 26, 2025
@github-actions
Copy link

github-actions bot commented Jun 26, 2025

API Change Check

APIView identified API level changes in this PR and created the following API reviews

azure_storage_blob

@vincenttran-msft vincenttran-msft changed the title [Storage] Lease operations for BlobClient and BlobContainerClient [Storage] Lease operations for BlobClient and BlobContainerClient, feature parity for AppendBlobClient Jul 10, 2025
@vincenttran-msft vincenttran-msft marked this pull request as ready for review July 10, 2025 19:25
@Copilot Copilot AI review requested due to automatic review settings July 10, 2025 19:25
Copy link
Contributor

@Copilot Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull Request Overview

This PR introduces lease management operations to BlobClient and BlobContainerClient and adds full append-blob support to AppendBlobClient. It includes new API methods, updated models, and end-to-end tests for these features.

  • Added acquire_lease, break_lease, change_lease, release_lease, and renew_lease methods (and related options/results) for blobs and containers
  • Completed AppendBlobClient with append_block, append_block_from_url, and seal methods
  • Expanded test suites to cover leasing and append-blob workflows

Reviewed Changes

Copilot reviewed 9 out of 13 changed files in this pull request and generated no comments.

Show a summary per file
File Description
tsp-location.yaml Updated commit hash for spec linkage
tests/blob_container_client.rs Added lease operation imports and new container lease test
tests/blob_client.rs Added blob lease tests and lease-aware operation tests
tests/append_blob_client.rs Added append-block, append-from-url, and seal tests for append blobs
src/models/mod.rs Expanded model exports for lease and append-blob operations
src/clients/blob_container_client.rs Implemented container lease methods and docs
src/clients/blob_client.rs Implemented blob lease methods and docs
src/clients/append_blob_client.rs Implemented append-blob methods and docs
assets.json Bumped SDK assets tag

@vincenttran-msft vincenttran-msft enabled auto-merge (squash) July 11, 2025 01:35
@vincenttran-msft vincenttran-msft merged commit ff85ac8 into Azure:main Jul 11, 2025
17 checks passed
@vincenttran-msft vincenttran-msft deleted the vincenttran/lease_ops branch July 11, 2025 01:52
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Storage Storage Service (Queues, Blobs, Files)

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants