CloudStorageAccount for Azure Storage v12+ > This project uses SponsorLink and may issue IDE-only warnings if no active sponsorship is detected. > Learn more at https://github.com/devlooped#sponsorlink.
$ dotnet add package Devlooped.CloudStorageAccountThe new unified Azure Storage and Tables client libraries do away with the CloudStorageAccount that was typically used. This makes migration a bit painful, as noted in:
This package provides a (mostly) drop-in replacement, with source code brought (and updated)
from the original location.
Just replace the old namespace Microsoft.Azure.Storage with Devlooped and you're mostly done.
In addition to the legacy, backwards-compatible APIs so projects compile right away with this package when upgrading to v12 client libraries, there are a few newer APIs that are more aligned with the new APIs, such as:
These make it more explicit that you're creating instances of the new service clients.
var account = CloudStorageAccount.DevelopmentStorageAccount;
var tableService = account.CreateTableServiceClient();
// legacy invocation works too: account.CreateCloudTableClient();
// Can also access the endpoints for each service:
Console.WriteLine(account.BlobEndpoint);
Console.WriteLine(account.QueueEndpoint);
Console.WriteLine(account.TableEndpoint);
To ensure the long-term sustainability of this project, users of this package who generate revenue must pay an Open Source Maintenance Fee. While the source code is freely available under the terms of the License, this package and other aspects of the project require adherence to the Maintenance Fee.
To pay the Maintenance Fee, become a Sponsor at the proper OSMF tier. A single fee covers all of Devlooped packages.