We have wrappers around blob storage SDK (CloudBlobWrapper, CloudBlobContainerWrapper, CloudBlobClientWrapper), unfortunately, they leak underlying SDK types as function arguments, return types and exceptions thrown, which defeats the purpose and complicates swapping the underlying implementation.
This change aims to stop that leakage. Introduced more wrappers around concepts that we use (BlobListContinuationToken, CloudBlobCopyState, CloudBlobCopyStatus, CloudBlobLocationMode, CloudBlobPropertiesWrapper, ListingDetails), propagated other wrappers that we had, but didn't use everywhere (AccessConditionWrapper, FileUriPermissions), wrapped StorageException with our own exception hierarchy following the checks existing in the code, simplifying catch expressions.
Addresses: https://github.com/NuGet/Engineering/issues/5456
We have wrappers around blob storage SDK (
CloudBlobWrapper
,CloudBlobContainerWrapper
,CloudBlobClientWrapper
), unfortunately, they leak underlying SDK types as function arguments, return types and exceptions thrown, which defeats the purpose and complicates swapping the underlying implementation.This change aims to stop that leakage. Introduced more wrappers around concepts that we use (
BlobListContinuationToken
,CloudBlobCopyState
,CloudBlobCopyStatus
,CloudBlobLocationMode
,CloudBlobPropertiesWrapper
,ListingDetails
), propagated other wrappers that we had, but didn't use everywhere (AccessConditionWrapper
,FileUriPermissions
), wrappedStorageException
with our own exception hierarchy following the checks existing in the code, simplifying catch expressions.