[Storage] exists() for BlobClient and BlobContainerClient#3010
Merged
vincenttran-msft merged 6 commits intoAzure:mainfrom Sep 17, 2025
Merged
[Storage] exists() for BlobClient and BlobContainerClient#3010vincenttran-msft merged 6 commits intoAzure:mainfrom
exists() for BlobClient and BlobContainerClient#3010vincenttran-msft merged 6 commits intoAzure:mainfrom
Conversation
…g tests, re-record
API Change CheckAPIView identified API level changes in this PR and created the following API reviews |
Contributor
There was a problem hiding this comment.
Pull Request Overview
This PR adds convenience exists() methods to both BlobClient and BlobContainerClient that return a boolean indicating whether the resource exists. The implementation uses the existing get_properties() method and returns true if the call succeeds or false if it fails.
- Added
exists()method toBlobClientandBlobContainerClient - Added comprehensive test coverage for the new methods
- Updated test asset tag
Reviewed Changes
Copilot reviewed 5 out of 5 changed files in this pull request and generated 2 comments.
Show a summary per file
| File | Description |
|---|---|
| sdk/storage/azure_storage_blob/src/clients/blob_client.rs | Added exists() method that checks blob existence using get_properties() |
| sdk/storage/azure_storage_blob/src/clients/blob_container_client.rs | Added exists() method that checks container existence using get_properties() |
| sdk/storage/azure_storage_blob/tests/blob_client.rs | Added test assertions for blob existence checks in various scenarios |
| sdk/storage/azure_storage_blob/tests/blob_container_client.rs | Added test assertions for container existence checks |
| sdk/storage/azure_storage_blob/assets.json | Updated test asset tag |
sdk/storage/azure_storage_blob/src/clients/blob_container_client.rs
Outdated
Show resolved
Hide resolved
heaths
requested changes
Sep 17, 2025
heaths
reviewed
Sep 17, 2025
heaths
approved these changes
Sep 17, 2025
jalauzon-msft
approved these changes
Sep 17, 2025
heaths
approved these changes
Sep 17, 2025
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
.tsp:Azure/azure-rest-api-specs#37542exists()forBlobClientandBlobContainerClientStorageErrorCodeenum from generated code changes.