Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[LIBCLOUD-851] Fix azure_blobs driver with BlobStorage account #1294

Merged
merged 1 commit into from
Jun 22, 2019
Merged

[LIBCLOUD-851] Fix azure_blobs driver with BlobStorage account #1294

merged 1 commit into from
Jun 22, 2019

Conversation

c-w
Copy link
Member

@c-w c-w commented May 31, 2019

Fix azure_blobs driver with BlobStorage account

Description

As discussed in LIBCLOUD-851, the Azure Storage driver currently doesn't work when used against a storage account that was created using kind=BlobStorage (see failed integration test). This is because BlobStorage accounts only work with API version 2014-02-14 or newer (see docs). Updating the API version fixes the problem and doesn't affect the other types of storage accounts (see passed integration test).

Note that this pull request is based on the work of @daviskirk in #1202.

Status

Checklist (tick everything that applies)

As per https://docs.microsoft.com/en-us/rest/api/storagerp/storageaccounts/create#kind,
there are several types of storage accounts that can be created in Azure
including: StorageV2 (default), Storage and BlobStorage.

As per https://docs.microsoft.com/en-us/rest/api/storageservices/versioning-for-the-azure-storage-services,
StorageV2 and Storage support API versions of `2009-09-19` or newer.
BlobStorage only supports API versions of `2014-02-14` or newer.

In order to ensure that libcloud works with all the types of storage
accounts, this change raises the API version used by the storage driver
to the earliest version supported by all the account types.
@c-w c-w mentioned this pull request May 31, 2019
4 tasks
@codecov-io
Copy link

Codecov Report

Merging #1294 into trunk will decrease coverage by <.01%.
The diff coverage is 100%.

Impacted file tree graph

@@            Coverage Diff             @@
##            trunk    #1294      +/-   ##
==========================================
- Coverage   85.95%   85.95%   -0.01%     
==========================================
  Files         359      359              
  Lines       73911    73912       +1     
  Branches     6705     6705              
==========================================
- Hits        63530    63529       -1     
- Misses       7699     7700       +1     
- Partials     2682     2683       +1
Impacted Files Coverage Δ
libcloud/common/azure.py 84% <100%> (ø) ⬆️
libcloud/storage/drivers/azure_blobs.py 68.52% <100%> (+0.09%) ⬆️
libcloud/test/compute/test_upcloud.py 90.06% <0%> (-1.33%) ⬇️

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update 7a948b1...aa788ee. Read the comment docs.

@c-w
Copy link
Member Author

c-w commented May 31, 2019

@cicorias @michaelperel @jmspring could one of you please review this?

Copy link

@cicorias cicorias left a comment

Choose a reason for hiding this comment

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

LGTM

@Kami
Copy link
Member

Kami commented Jun 22, 2019

@c-w I was hoping you will be able to merge this yourself :)

@asfgit asfgit merged commit aa788ee into apache:trunk Jun 22, 2019
asfgit pushed a commit that referenced this pull request Jun 22, 2019
@Kami
Copy link
Member

Kami commented Jun 22, 2019

I went ahead and merged this bug fix into trunk.

Thanks @c-w and @daviskirk.

@c-w c-w deleted the 851_fix-azure-blobstorage branch June 23, 2019 02:17
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants