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

Implement SAS URL generation for Azure Storage #1408

Merged
merged 1 commit into from Jan 14, 2020

Conversation

@c-w
Copy link
Member

c-w commented Jan 10, 2020

Implement SAS URL generation for Azure Storage

Description

As discussed in #1403, this pull request implements AzureBlobsStorageDriver.get_object_cdn_url via a service SAS.

Status

  • done, ready for review

Checklist

@codecov-io

This comment has been minimized.

Copy link

codecov-io commented Jan 10, 2020

Codecov Report

Merging #1408 into trunk will increase coverage by <.01%.
The diff coverage is 100%.

Impacted file tree graph

@@            Coverage Diff             @@
##            trunk    #1408      +/-   ##
==========================================
+ Coverage   86.44%   86.45%   +<.01%     
==========================================
  Files         366      366              
  Lines       76767    76785      +18     
  Branches     7529     7529              
==========================================
+ Hits        66365    66383      +18     
  Misses       7534     7534              
  Partials     2868     2868
Impacted Files Coverage Δ
libcloud/test/storage/test_azure_blobs.py 94.34% <100%> (+0.07%) ⬆️
libcloud/storage/drivers/azure_blobs.py 85.62% <100%> (+0.53%) ⬆️

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 435d82b...885bc52. Read the comment docs.

@c-w c-w force-pushed the CatalystCode:azure-sas-url branch from dfc2321 to 885bc52 Jan 10, 2020
@Kami
Kami approved these changes Jan 14, 2020
Copy link
Member

Kami left a comment

LGTM 👍

@@ -489,6 +503,70 @@ def get_object(self, container_name, object_name):
raise ObjectDoesNotExistError(value=None, driver=self,
object_name=object_name)

def get_object_cdn_url(self, obj,
ex_expiry=AZURE_STORAGE_CDN_URL_EXPIRY_HOURS):

This comment has been minimized.

Copy link
@Kami

Kami Jan 14, 2020

Member

Going forward, we can also start adding type annotations for various method arguments in the drivers when we introduce new functionality.

We now don't support Python 2.7 anymore, but perhaps we should still start with type annotations in the comments and move to putting them directly into the method signatures in the future.

This comment has been minimized.

Copy link
@c-w

c-w Jan 14, 2020

Author Member

I'll take a note to work on a follow-up PR with type annotations for the storage API.

@c-w c-w merged commit bb865b1 into apache:trunk Jan 14, 2020
1 check passed
1 check passed
continuous-integration/travis-ci/pr The Travis CI build passed
Details
@c-w c-w deleted the CatalystCode:azure-sas-url branch Jan 14, 2020
@c-w c-w mentioned this pull request Jan 14, 2020
4 of 4 tasks complete
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
3 participants
You can’t perform that action at this time.