Azure Block Blob¶
-
class
keg_storage.backends.azure.
AzureStorage
(account: str, key: str, bucket: str, name: str = 'azure')[source]¶
-
class
keg_storage.backends.azure.
AzureReader
(container_name: str, path: str, mode: keg_storage.backends.base.FileMode, service: azure.storage.blob.blockblobservice.BlockBlobService, chunk_size=10485760)[source]¶ The Azure reader uses byte ranged API calls to fill a local buffer to avoid lots of API overhead for small read sizes.
-
class
keg_storage.backends.azure.
AzureWriter
(container_name: str, path: str, mode: keg_storage.backends.base.FileMode, service: azure.storage.blob.blockblobservice.BlockBlobService, chunk_size: int = 4194304)[source]¶ We are using Azure Block Blobs for all operations. The process for writing them is substantially similar to that of S3 with a couple of differences.
- We generate the IDs for the blocks
- There is no separate call to instantiate the upload. The first call to put_block will create the blob.
-
class
keg_storage.backends.azure.
AzureFile
(container_name: str, path: str, mode: keg_storage.backends.base.FileMode, service: azure.storage.blob.blockblobservice.BlockBlobService, chunk_size: int = 10485760)[source]¶ Base class for Azure file interface. Since read and write operations are very different and integrating the two would introduce a lot of complexity there are distinct subclasses for files opened for reading and writing.