diff --git a/sdk/storage/azure-storage-blob/HISTORY.md b/sdk/storage/azure-storage-blob/HISTORY.md index b4567c2f91b4..589ad149ff7a 100644 --- a/sdk/storage/azure-storage-blob/HISTORY.md +++ b/sdk/storage/azure-storage-blob/HISTORY.md @@ -24,6 +24,7 @@ - `Logging` has been renamed to `BlobAnalyticsLogging`. - All operations that take Etag conditional parameters (`if_match` and `if_none_match`) now take explicit `etag` and `match_condition` parameters, where `etag` is the Etag value, and `match_condition` is an instance of `azure.core.MatchConditions`. - The `generate_shared_access_signature` methods on each of `BlobServiceClient`, `ContainerClient` and `BlobClient` have been replaced by module level functions `generate_account_sas`, `generate_container_sas` and `generate_blob_sas`. +- The batch APIs now have an additional keyword only argument `raise_on_any_failure` which defaults to True. This will raise an error even if there's a partial batch failure. **New features** diff --git a/sdk/storage/azure-storage-blob/azure/storage/blob/__init__.py b/sdk/storage/azure-storage-blob/azure/storage/blob/__init__.py index 8e1f2c6354c6..a26a856358cd 100644 --- a/sdk/storage/azure-storage-blob/azure/storage/blob/__init__.py +++ b/sdk/storage/azure-storage-blob/azure/storage/blob/__init__.py @@ -15,6 +15,7 @@ from .download import StorageStreamDownloader from ._shared_access_signature import generate_account_sas, generate_container_sas, generate_blob_sas from ._shared.policies import ExponentialRetry, LinearRetry +from ._shared.response_handlers import PartialBatchErrorException from ._shared.models import( LocationMode, ResourceTypes, @@ -203,5 +204,6 @@ def download_blob_from_url( 'RehydratePriority', 'generate_account_sas', 'generate_container_sas', - 'generate_blob_sas' + 'generate_blob_sas', + 'PartialBatchErrorException' ] diff --git a/sdk/storage/azure-storage-blob/azure/storage/blob/_shared/base_client.py b/sdk/storage/azure-storage-blob/azure/storage/blob/_shared/base_client.py index 93f83c839ea4..1a6e77a9c5f8 100644 --- a/sdk/storage/azure-storage-blob/azure/storage/blob/_shared/base_client.py +++ b/sdk/storage/azure-storage-blob/azure/storage/blob/_shared/base_client.py @@ -53,7 +53,7 @@ ExponentialRetry, ) from .._generated.models import StorageErrorException -from .response_handlers import process_storage_error +from .response_handlers import process_storage_error, PartialBatchErrorException _LOGGER = logging.getLogger(__name__) @@ -197,6 +197,8 @@ def _batch_send( ): """Given a series of request, do a Storage batch call. """ + # Pop it here, so requests doesn't feel bad about additional kwarg + raise_on_any_failure = kwargs.pop("raise_on_any_failure", True) request = self._client._client.post( # pylint: disable=protected-access url='https://{}/?comp=batch'.format(self.primary_hostname), headers={ @@ -220,7 +222,17 @@ def _batch_send( try: if response.status_code not in [202]: raise HttpResponseError(response=response) - return response.parts() + parts = response.parts() + if raise_on_any_failure: + parts = list(response.parts()) + if any(p for p in parts if not 200 <= p.status_code < 300): + error = PartialBatchErrorException( + message="There is a partial failure in the batch operation.", + response=response, parts=parts + ) + raise error + return iter(parts) + return parts except StorageErrorException as error: process_storage_error(error) diff --git a/sdk/storage/azure-storage-blob/azure/storage/blob/_shared/base_client_async.py b/sdk/storage/azure-storage-blob/azure/storage/blob/_shared/base_client_async.py index 215292a64f3e..a795e5ed7655 100644 --- a/sdk/storage/azure-storage-blob/azure/storage/blob/_shared/base_client_async.py +++ b/sdk/storage/azure-storage-blob/azure/storage/blob/_shared/base_client_async.py @@ -9,8 +9,8 @@ TYPE_CHECKING ) import logging - from azure.core.pipeline import AsyncPipeline +from azure.core.async_paging import AsyncList from azure.core.exceptions import HttpResponseError from azure.core.pipeline.policies import ( ContentDecodePolicy, @@ -33,7 +33,7 @@ from .policies_async import AsyncStorageResponseHook from .._generated.models import StorageErrorException -from .response_handlers import process_storage_error +from .response_handlers import process_storage_error, PartialBatchErrorException if TYPE_CHECKING: from azure.core.pipeline import Pipeline @@ -101,6 +101,8 @@ async def _batch_send( ): """Given a series of request, do a Storage batch call. """ + # Pop it here, so requests doesn't feel bad about additional kwarg + raise_on_any_failure = kwargs.pop("raise_on_any_failure", True) request = self._client._client.post( # pylint: disable=protected-access url='https://{}/?comp=batch'.format(self.primary_hostname), headers={ @@ -124,7 +126,19 @@ async def _batch_send( try: if response.status_code not in [202]: raise HttpResponseError(response=response) - return response.parts() # Return an AsyncIterator + parts = response.parts() # Return an AsyncIterator + if raise_on_any_failure: + parts_list = [] + async for part in parts: + parts_list.append(part) + if any(p for p in parts_list if not 200 <= p.status_code < 300): + error = PartialBatchErrorException( + message="There is a partial failure in the batch operation.", + response=response, parts=parts_list + ) + raise error + return AsyncList(parts_list) + return parts except StorageErrorException as error: process_storage_error(error) diff --git a/sdk/storage/azure-storage-blob/azure/storage/blob/_shared/response_handlers.py b/sdk/storage/azure-storage-blob/azure/storage/blob/_shared/response_handlers.py index fbf9889d762c..ce625d589504 100644 --- a/sdk/storage/azure-storage-blob/azure/storage/blob/_shared/response_handlers.py +++ b/sdk/storage/azure-storage-blob/azure/storage/blob/_shared/response_handlers.py @@ -31,6 +31,19 @@ _LOGGER = logging.getLogger(__name__) +class PartialBatchErrorException(HttpResponseError): + """There is a partial failure in batch operations. + + :param message: The message of the exception. + :param response: Server response to be deserialized. + :param parts: A list of the parts in multipart response. + """ + + def __init__(self, message, response, parts): + self.parts = parts + super(PartialBatchErrorException, self).__init__(message=message, response=response) + + def parse_length_from_content_range(content_range): ''' Parses the blob length from the content range header: bytes 1-3/65537 diff --git a/sdk/storage/azure-storage-blob/azure/storage/blob/aio/container_client_async.py b/sdk/storage/azure-storage-blob/azure/storage/blob/aio/container_client_async.py index 7f647c77830e..91e2452a1488 100644 --- a/sdk/storage/azure-storage-blob/azure/storage/blob/aio/container_client_async.py +++ b/sdk/storage/azure-storage-blob/azure/storage/blob/aio/container_client_async.py @@ -800,6 +800,10 @@ async def delete_blobs( # pylint: disable=arguments-differ If a date is passed in without timezone info, it is assumed to be UTC. Specify this header to perform the operation only if the resource has not been modified since the specified date/time. + :keyword bool raise_on_any_failure: + This is a boolean param which defaults to True. When this is set, an exception + is raised even if there is a single operation failure. For optimal performance, + this should be set to False :keyword str etag: An ETag value, or the wildcard character (*). Used to check if the resource has changed, and act according to the condition specified by the `match_condition` parameter. @@ -810,6 +814,7 @@ async def delete_blobs( # pylint: disable=arguments-differ :return: An async iterator of responses, one for each blob in order :rtype: asynciterator[~azure.core.pipeline.transport.AsyncHttpResponse] """ + raise_on_any_failure = kwargs.pop('raise_on_any_failure', True) timeout = kwargs.pop('timeout', None) options = BlobClient._generic_delete_blob_options( # pylint: disable=protected-access delete_snapshots=delete_snapshots, @@ -817,6 +822,7 @@ async def delete_blobs( # pylint: disable=arguments-differ timeout=timeout, **kwargs ) + options.update({'raise_on_any_failure': raise_on_any_failure}) query_parameters, header_parameters = self._generate_delete_blobs_options(**options) # To pass kwargs to "_batch_send", we need to remove anything that was # in the Autorest signature for Autorest, otherwise transport will be upset @@ -863,6 +869,10 @@ async def set_standard_blob_tier_blobs( Required if the blob has an active lease. Value can be a LeaseClient object or the lease ID as a string. :type lease: ~azure.storage.blob.lease.LeaseClient or str + :keyword bool raise_on_any_failure: + This is a boolean param which defaults to True. When this is set, an exception + is raised even if there is a single operation failure. For optimal performance, + this should be set to False. :return: An async iterator of responses, one for each blob in order :rtype: asynciterator[~azure.core.pipeline.transport.AsyncHttpResponse] """ @@ -916,6 +926,10 @@ async def set_premium_page_blob_tier_blobs( Required if the blob has an active lease. Value can be a LeaseClient object or the lease ID as a string. :type lease: ~azure.storage.blob.lease.LeaseClient or str + :keyword bool raise_on_any_failure: + This is a boolean param which defaults to True. When this is set, an exception + is raised even if there is a single operation failure. For optimal performance, + this should be set to False. :return: An async iterator of responses, one for each blob in order :rtype: asynciterator[~azure.core.pipeline.transport.AsyncHttpResponse] """ diff --git a/sdk/storage/azure-storage-blob/azure/storage/blob/container_client.py b/sdk/storage/azure-storage-blob/azure/storage/blob/container_client.py index cecaf7f3466e..8be14c88a6ee 100644 --- a/sdk/storage/azure-storage-blob/azure/storage/blob/container_client.py +++ b/sdk/storage/azure-storage-blob/azure/storage/blob/container_client.py @@ -952,6 +952,9 @@ def delete_blobs(self, *blobs, **kwargs): If a date is passed in without timezone info, it is assumed to be UTC. Specify this header to perform the operation only if the resource has not been modified since the specified date/time. + :keyword bool raise_on_any_failure: + This is a boolean param which defaults to True. When this is set, an exception + is raised even if there is a single operation failure. :keyword str etag: An ETag value, or the wildcard character (*). Used to check if the resource has changed, and act according to the condition specified by the `match_condition` parameter. @@ -962,9 +965,11 @@ def delete_blobs(self, *blobs, **kwargs): :return: An iterator of responses, one for each blob in order :rtype: iterator[~azure.core.pipeline.transport.HttpResponse] """ + raise_on_any_failure = kwargs.pop('raise_on_any_failure', True) options = BlobClient._generic_delete_blob_options( # pylint: disable=protected-access **kwargs ) + options.update({'raise_on_any_failure': raise_on_any_failure}) query_parameters, header_parameters = self._generate_delete_blobs_options(**options) # To pass kwargs to "_batch_send", we need to remove anything that was # in the Autorest signature for Autorest, otherwise transport will be upset @@ -1045,6 +1050,9 @@ def set_standard_blob_tier_blobs( Required if the blob has an active lease. Value can be a LeaseClient object or the lease ID as a string. :type lease: ~azure.storage.blob.LeaseClient or str + :keyword bool raise_on_any_failure: + This is a boolean param which defaults to True. When this is set, an exception + is raised even if there is a single operation failure. :return: An iterator of responses, one for each blob in order :rtype: iterator[~azure.core.pipeline.transport.HttpResponse] """ @@ -1099,6 +1107,9 @@ def set_premium_page_blob_tier_blobs( Required if the blob has an active lease. Value can be a LeaseClient object or the lease ID as a string. :type lease: ~azure.storage.blob.LeaseClient or str + :keyword bool raise_on_any_failure: + This is a boolean param which defaults to True. When this is set, an exception + is raised even if there is a single operation failure. :return: An iterator of responses, one for each blob in order :rtype: iterator[~azure.core.pipeline.transport.HttpResponse] """ diff --git a/sdk/storage/azure-storage-blob/tests/recordings/test_container.test_delete_blobs_simple_no_raise.yaml b/sdk/storage/azure-storage-blob/tests/recordings/test_container.test_delete_blobs_simple_no_raise.yaml new file mode 100644 index 000000000000..3226606d367d --- /dev/null +++ b/sdk/storage/azure-storage-blob/tests/recordings/test_container.test_delete_blobs_simple_no_raise.yaml @@ -0,0 +1,266 @@ +interactions: +- request: + body: null + headers: + Accept: + - '*/*' + Accept-Encoding: + - gzip, deflate + Connection: + - keep-alive + Content-Length: + - '0' + User-Agent: + - azsdk-python-storage-blob/12.0.0b4 Python/3.7.3 (Windows-10-10.0.17763-SP0) + x-ms-client-request-id: + - c9c8f12c-f438-11e9-baff-2816a845e8c6 + x-ms-date: + - Mon, 21 Oct 2019 19:27:15 GMT + x-ms-version: + - '2019-02-02' + method: PUT + uri: https://storagename.blob.core.windows.net/containere26513ac?restype=container + response: + body: + string: '' + headers: + Content-Length: + - '0' + Date: + - Mon, 21 Oct 2019 19:27:15 GMT + ETag: + - '"0x8D7565CAE1D8017"' + Last-Modified: + - Mon, 21 Oct 2019 19:27:15 GMT + Server: + - Windows-Azure-Blob/1.0 Microsoft-HTTPAPI/2.0 + x-ms-request-id: + - 05fa205a-801e-0098-1145-88ea3f000000 + x-ms-version: + - '2019-02-02' + status: + code: 201 + message: Created +- request: + body: hello world + headers: + Accept: + - '*/*' + Accept-Encoding: + - gzip, deflate + Connection: + - keep-alive + Content-Length: + - '11' + Content-Type: + - application/octet-stream + If-None-Match: + - '*' + User-Agent: + - azsdk-python-storage-blob/12.0.0b4 Python/3.7.3 (Windows-10-10.0.17763-SP0) + x-ms-blob-type: + - BlockBlob + x-ms-client-request-id: + - ca066e64-f438-11e9-8880-2816a845e8c6 + x-ms-date: + - Mon, 21 Oct 2019 19:27:15 GMT + x-ms-version: + - '2019-02-02' + method: PUT + uri: https://storagename.blob.core.windows.net/containere26513ac/blob1 + response: + body: + string: '' + headers: + Content-Length: + - '0' + Content-MD5: + - XrY7u+Ae7tCTyyK7j1rNww== + Date: + - Mon, 21 Oct 2019 19:27:15 GMT + ETag: + - '"0x8D7565CAE344DCA"' + Last-Modified: + - Mon, 21 Oct 2019 19:27:15 GMT + Server: + - Windows-Azure-Blob/1.0 Microsoft-HTTPAPI/2.0 + x-ms-content-crc64: + - vo7q9sPVKY0= + x-ms-request-id: + - 05fa2095-801e-0098-3f45-88ea3f000000 + x-ms-request-server-encrypted: + - 'true' + x-ms-version: + - '2019-02-02' + status: + code: 201 + message: Created +- request: + body: hello world + headers: + Accept: + - '*/*' + Accept-Encoding: + - gzip, deflate + Connection: + - keep-alive + Content-Length: + - '11' + Content-Type: + - application/octet-stream + If-None-Match: + - '*' + User-Agent: + - azsdk-python-storage-blob/12.0.0b4 Python/3.7.3 (Windows-10-10.0.17763-SP0) + x-ms-blob-type: + - BlockBlob + x-ms-client-request-id: + - ca177786-f438-11e9-8167-2816a845e8c6 + x-ms-date: + - Mon, 21 Oct 2019 19:27:15 GMT + x-ms-version: + - '2019-02-02' + method: PUT + uri: https://storagename.blob.core.windows.net/containere26513ac/blob2 + response: + body: + string: '' + headers: + Content-Length: + - '0' + Content-MD5: + - XrY7u+Ae7tCTyyK7j1rNww== + Date: + - Mon, 21 Oct 2019 19:27:15 GMT + ETag: + - '"0x8D7565CAE4344A1"' + Last-Modified: + - Mon, 21 Oct 2019 19:27:15 GMT + Server: + - Windows-Azure-Blob/1.0 Microsoft-HTTPAPI/2.0 + x-ms-content-crc64: + - vo7q9sPVKY0= + x-ms-request-id: + - 05fa20bf-801e-0098-5f45-88ea3f000000 + x-ms-request-server-encrypted: + - 'true' + x-ms-version: + - '2019-02-02' + status: + code: 201 + message: Created +- request: + body: hello world + headers: + Accept: + - '*/*' + Accept-Encoding: + - gzip, deflate + Connection: + - keep-alive + Content-Length: + - '11' + Content-Type: + - application/octet-stream + If-None-Match: + - '*' + User-Agent: + - azsdk-python-storage-blob/12.0.0b4 Python/3.7.3 (Windows-10-10.0.17763-SP0) + x-ms-blob-type: + - BlockBlob + x-ms-client-request-id: + - ca26616e-f438-11e9-8d59-2816a845e8c6 + x-ms-date: + - Mon, 21 Oct 2019 19:27:15 GMT + x-ms-version: + - '2019-02-02' + method: PUT + uri: https://storagename.blob.core.windows.net/containere26513ac/blob3 + response: + body: + string: '' + headers: + Content-Length: + - '0' + Content-MD5: + - XrY7u+Ae7tCTyyK7j1rNww== + Date: + - Mon, 21 Oct 2019 19:27:15 GMT + ETag: + - '"0x8D7565CAE519F1D"' + Last-Modified: + - Mon, 21 Oct 2019 19:27:15 GMT + Server: + - Windows-Azure-Blob/1.0 Microsoft-HTTPAPI/2.0 + x-ms-content-crc64: + - vo7q9sPVKY0= + x-ms-request-id: + - 05fa20d5-801e-0098-7245-88ea3f000000 + x-ms-request-server-encrypted: + - 'true' + x-ms-version: + - '2019-02-02' + status: + code: 201 + message: Created +- request: + body: "--===============0499579814==\r\nContent-Type: application/http\r\nContent-Transfer-Encoding: + binary\r\nContent-ID: 0\r\n\r\nDELETE /containere26513ac/blob1? HTTP/1.1\r\nx-ms-date: + Mon, 21 Oct 2019 19:27:15 GMT\r\nx-ms-client-request-id: ca352482-f438-11e9-b6c8-2816a845e8c6\r\nAuthorization: + SharedKey storagename:q4u3XQVy39ZtlRVgRbbwm57aQ5bG7sSVe5migY3yj+s=\r\n\r\n\r\n--===============0499579814==\r\nContent-Type: + application/http\r\nContent-Transfer-Encoding: binary\r\nContent-ID: 1\r\n\r\nDELETE + /containere26513ac/blob2? HTTP/1.1\r\nx-ms-date: Mon, 21 Oct 2019 19:27:15 GMT\r\nx-ms-client-request-id: + ca354b82-f438-11e9-9602-2816a845e8c6\r\nAuthorization: SharedKey storagename:KD2jTEyaDPrgU+NQkF/0PtNwnZmK1RP1Hq0rjwniqlc=\r\n\r\n\r\n--===============0499579814==\r\nContent-Type: + application/http\r\nContent-Transfer-Encoding: binary\r\nContent-ID: 2\r\n\r\nDELETE + /containere26513ac/blob3? HTTP/1.1\r\nx-ms-date: Mon, 21 Oct 2019 19:27:15 GMT\r\nx-ms-client-request-id: + ca359978-f438-11e9-b3df-2816a845e8c6\r\nAuthorization: SharedKey storagename:Jnn/BFigZHorBTId/p6hnIxsB92m2n0Ir7kzPRqohVM=\r\n\r\n\r\n--===============0499579814==--\r\n" + headers: + Accept: + - '*/*' + Accept-Encoding: + - gzip, deflate + Connection: + - keep-alive + Content-Length: + - '1071' + Content-Type: + - multipart/mixed; boundary================0499579814== + User-Agent: + - azsdk-python-storage-blob/12.0.0b4 Python/3.7.3 (Windows-10-10.0.17763-SP0) + x-ms-client-request-id: + - ca3b88ca-f438-11e9-ba8a-2816a845e8c6 + x-ms-date: + - Mon, 21 Oct 2019 19:27:15 GMT + x-ms-version: + - '2019-02-02' + method: POST + uri: https://storagename.blob.core.windows.net/?comp=batch + response: + body: + string: "--batchresponse_2efae71e-dd6b-4405-9321-a09cc8966f72\r\nContent-Type: + application/http\r\nContent-ID: 0\r\n\r\nHTTP/1.1 202 Accepted\r\nx-ms-delete-status: + pending\r\nx-ms-delete-type-permanent: false\r\nx-ms-request-id: 05fa20f9-801e-0098-0e45-88ea3f1efca2\r\nx-ms-version: + 2019-02-02\r\nServer: Windows-Azure-Blob/1.0\r\n\r\n--batchresponse_2efae71e-dd6b-4405-9321-a09cc8966f72\r\nContent-Type: + application/http\r\nContent-ID: 1\r\n\r\nHTTP/1.1 202 Accepted\r\nx-ms-delete-status: + pending\r\nx-ms-delete-type-permanent: false\r\nx-ms-request-id: 05fa20f9-801e-0098-0e45-88ea3f1efca4\r\nx-ms-version: + 2019-02-02\r\nServer: Windows-Azure-Blob/1.0\r\n\r\n--batchresponse_2efae71e-dd6b-4405-9321-a09cc8966f72\r\nContent-Type: + application/http\r\nContent-ID: 2\r\n\r\nHTTP/1.1 202 Accepted\r\nx-ms-delete-status: + pending\r\nx-ms-delete-type-permanent: false\r\nx-ms-request-id: 05fa20f9-801e-0098-0e45-88ea3f1efca5\r\nx-ms-version: + 2019-02-02\r\nServer: Windows-Azure-Blob/1.0\r\n\r\n--batchresponse_2efae71e-dd6b-4405-9321-a09cc8966f72--" + headers: + Content-Type: + - multipart/mixed; boundary=batchresponse_2efae71e-dd6b-4405-9321-a09cc8966f72 + Date: + - Mon, 21 Oct 2019 19:27:15 GMT + Server: + - Windows-Azure-Blob/1.0 Microsoft-HTTPAPI/2.0 + Transfer-Encoding: + - chunked + x-ms-request-id: + - 05fa20f9-801e-0098-0e45-88ea3f000000 + x-ms-version: + - '2019-02-02' + status: + code: 202 + message: Accepted +version: 1 diff --git a/sdk/storage/azure-storage-blob/tests/recordings/test_container.test_standard_blob_tier_set_tier_api_batch.yaml b/sdk/storage/azure-storage-blob/tests/recordings/test_container.test_standard_blob_tier_set_tier_api_batch.yaml index 3598cbef77e2..a3208b725429 100644 --- a/sdk/storage/azure-storage-blob/tests/recordings/test_container.test_standard_blob_tier_set_tier_api_batch.yaml +++ b/sdk/storage/azure-storage-blob/tests/recordings/test_container.test_standard_blob_tier_set_tier_api_batch.yaml @@ -1319,4 +1319,1337 @@ interactions: status: code: 202 message: Accepted +- request: + body: null + headers: + Accept: + - '*/*' + Accept-Encoding: + - gzip, deflate + Connection: + - keep-alive + Content-Length: + - '0' + User-Agent: + - azsdk-python-storage-blob/12.0.0b4 Python/3.7.3 (Windows-10-10.0.17763-SP0) + x-ms-client-request-id: + - 8f52b076-f1e4-11e9-828f-2816a845e8c6 + x-ms-date: + - Fri, 18 Oct 2019 20:19:17 GMT + x-ms-version: + - '2019-02-02' + method: PUT + uri: https://blobstoragename.blob.core.windows.net/containera687174a?restype=container + response: + body: + string: "\uFEFFContainerAlreadyExistsThe + specified container already exists.\nRequestId:ecec2d98-401e-00ac-7bf1-854597000000\nTime:2019-10-18T20:19:16.5496175Z" + headers: + Content-Length: + - '230' + Content-Type: + - application/xml + Date: + - Fri, 18 Oct 2019 20:19:16 GMT + Server: + - Windows-Azure-Blob/1.0 Microsoft-HTTPAPI/2.0 + x-ms-error-code: + - ContainerAlreadyExists + x-ms-request-id: + - ecec2d98-401e-00ac-7bf1-854597000000 + x-ms-version: + - '2019-02-02' + status: + code: 409 + message: The specified container already exists. +- request: + body: "--===============0874942346==\r\nContent-Type: application/http\r\nContent-Transfer-Encoding: + binary\r\nContent-ID: 0\r\n\r\nDELETE /containera687174a/blob1? HTTP/1.1\r\nx-ms-date: + Fri, 18 Oct 2019 20:19:17 GMT\r\nx-ms-client-request-id: 8f98fe14-f1e4-11e9-95c8-2816a845e8c6\r\nAuthorization: + SharedKey blobstoragename:dSiwALXA1UOw/16RwvZrVH+x8ScQ5rvXTEE4mYM8omo=\r\n\r\n\r\n--===============0874942346==\r\nContent-Type: + application/http\r\nContent-Transfer-Encoding: binary\r\nContent-ID: 1\r\n\r\nDELETE + /containera687174a/blob2? HTTP/1.1\r\nx-ms-date: Fri, 18 Oct 2019 20:19:17 GMT\r\nx-ms-client-request-id: + 8f98fe15-f1e4-11e9-819f-2816a845e8c6\r\nAuthorization: SharedKey blobstoragename:bgYwTwL8INPYV+f0qUCFGj26JcCFUKWqtCI/OsDrc28=\r\n\r\n\r\n--===============0874942346==\r\nContent-Type: + application/http\r\nContent-Transfer-Encoding: binary\r\nContent-ID: 2\r\n\r\nDELETE + /containera687174a/blob3? HTTP/1.1\r\nx-ms-date: Fri, 18 Oct 2019 20:19:17 GMT\r\nx-ms-client-request-id: + 8f9924e8-f1e4-11e9-b0ba-2816a845e8c6\r\nAuthorization: SharedKey blobstoragename:pGHwMN7U+riFvAC36v6dVnMss0zbyPdexrkJcfk/ZK0=\r\n\r\n\r\n--===============0874942346==--\r\n" + headers: + Accept: + - '*/*' + Accept-Encoding: + - gzip, deflate + Connection: + - keep-alive + Content-Length: + - '1071' + Content-Type: + - multipart/mixed; boundary================0874942346== + User-Agent: + - azsdk-python-storage-blob/12.0.0b4 Python/3.7.3 (Windows-10-10.0.17763-SP0) + x-ms-client-request-id: + - 8f9c58a8-f1e4-11e9-a96b-2816a845e8c6 + x-ms-date: + - Fri, 18 Oct 2019 20:19:17 GMT + x-ms-version: + - '2019-02-02' + method: POST + uri: https://blobstoragename.blob.core.windows.net/?comp=batch + response: + body: + string: "--batchresponse_0e520e71-9591-4ec3-a513-20160b9cd3bc\r\nContent-Type: + application/http\r\nContent-ID: 0\r\n\r\nHTTP/1.1 404 The specified blob does + not exist.\r\nx-ms-error-code: BlobNotFound\r\nx-ms-request-id: ecec2db3-401e-00ac-12f1-8545971e82d4\r\nx-ms-version: + 2019-02-02\r\nContent-Length: 216\r\nContent-Type: application/xml\r\nServer: + Windows-Azure-Blob/1.0\r\n\r\n\uFEFF\nBlobNotFoundThe + specified blob does not exist.\nRequestId:ecec2db3-401e-00ac-12f1-8545971e82d4\nTime:2019-10-18T20:19:16.8448259Z\r\n--batchresponse_0e520e71-9591-4ec3-a513-20160b9cd3bc\r\nContent-Type: + application/http\r\nContent-ID: 1\r\n\r\nHTTP/1.1 404 The specified blob does + not exist.\r\nx-ms-error-code: BlobNotFound\r\nx-ms-request-id: ecec2db3-401e-00ac-12f1-8545971e82d8\r\nx-ms-version: + 2019-02-02\r\nContent-Length: 216\r\nContent-Type: application/xml\r\nServer: + Windows-Azure-Blob/1.0\r\n\r\n\uFEFF\nBlobNotFoundThe + specified blob does not exist.\nRequestId:ecec2db3-401e-00ac-12f1-8545971e82d8\nTime:2019-10-18T20:19:16.8478280Z\r\n--batchresponse_0e520e71-9591-4ec3-a513-20160b9cd3bc\r\nContent-Type: + application/http\r\nContent-ID: 2\r\n\r\nHTTP/1.1 404 The specified blob does + not exist.\r\nx-ms-error-code: BlobNotFound\r\nx-ms-request-id: ecec2db3-401e-00ac-12f1-8545971e82d9\r\nx-ms-version: + 2019-02-02\r\nContent-Length: 216\r\nContent-Type: application/xml\r\nServer: + Windows-Azure-Blob/1.0\r\n\r\n\uFEFF\nBlobNotFoundThe + specified blob does not exist.\nRequestId:ecec2db3-401e-00ac-12f1-8545971e82d9\nTime:2019-10-18T20:19:16.8478280Z\r\n--batchresponse_0e520e71-9591-4ec3-a513-20160b9cd3bc--" + headers: + Content-Type: + - multipart/mixed; boundary=batchresponse_0e520e71-9591-4ec3-a513-20160b9cd3bc + Date: + - Fri, 18 Oct 2019 20:19:16 GMT + Server: + - Windows-Azure-Blob/1.0 Microsoft-HTTPAPI/2.0 + Transfer-Encoding: + - chunked + x-ms-request-id: + - ecec2db3-401e-00ac-12f1-854597000000 + x-ms-version: + - '2019-02-02' + status: + code: 202 + message: Accepted +- request: + body: hello world + headers: + Accept: + - '*/*' + Accept-Encoding: + - gzip, deflate + Connection: + - keep-alive + Content-Length: + - '11' + Content-Type: + - application/octet-stream + If-None-Match: + - '*' + User-Agent: + - azsdk-python-storage-blob/12.0.0b4 Python/3.7.3 (Windows-10-10.0.17763-SP0) + x-ms-blob-type: + - BlockBlob + x-ms-client-request-id: + - 8ff5ad28-f1e4-11e9-8b25-2816a845e8c6 + x-ms-date: + - Fri, 18 Oct 2019 20:19:18 GMT + x-ms-version: + - '2019-02-02' + method: PUT + uri: https://blobstoragename.blob.core.windows.net/containera687174a/blob1 + response: + body: + string: '' + headers: + Content-Length: + - '0' + Content-MD5: + - XrY7u+Ae7tCTyyK7j1rNww== + Date: + - Fri, 18 Oct 2019 20:19:17 GMT + ETag: + - '"0x8D7540873A08507"' + Last-Modified: + - Fri, 18 Oct 2019 20:19:17 GMT + Server: + - Windows-Azure-Blob/1.0 Microsoft-HTTPAPI/2.0 + x-ms-content-crc64: + - vo7q9sPVKY0= + x-ms-request-id: + - ecec2e4d-401e-00ac-1ef1-854597000000 + x-ms-request-server-encrypted: + - 'true' + x-ms-version: + - '2019-02-02' + status: + code: 201 + message: Created +- request: + body: hello world + headers: + Accept: + - '*/*' + Accept-Encoding: + - gzip, deflate + Connection: + - keep-alive + Content-Length: + - '11' + Content-Type: + - application/octet-stream + If-None-Match: + - '*' + User-Agent: + - azsdk-python-storage-blob/12.0.0b4 Python/3.7.3 (Windows-10-10.0.17763-SP0) + x-ms-blob-type: + - BlockBlob + x-ms-client-request-id: + - 900900f6-f1e4-11e9-87d7-2816a845e8c6 + x-ms-date: + - Fri, 18 Oct 2019 20:19:18 GMT + x-ms-version: + - '2019-02-02' + method: PUT + uri: https://blobstoragename.blob.core.windows.net/containera687174a/blob2 + response: + body: + string: '' + headers: + Content-Length: + - '0' + Content-MD5: + - XrY7u+Ae7tCTyyK7j1rNww== + Date: + - Fri, 18 Oct 2019 20:19:17 GMT + ETag: + - '"0x8D7540873B26290"' + Last-Modified: + - Fri, 18 Oct 2019 20:19:17 GMT + Server: + - Windows-Azure-Blob/1.0 Microsoft-HTTPAPI/2.0 + x-ms-content-crc64: + - vo7q9sPVKY0= + x-ms-request-id: + - ecec2e6c-401e-00ac-3bf1-854597000000 + x-ms-request-server-encrypted: + - 'true' + x-ms-version: + - '2019-02-02' + status: + code: 201 + message: Created +- request: + body: hello world + headers: + Accept: + - '*/*' + Accept-Encoding: + - gzip, deflate + Connection: + - keep-alive + Content-Length: + - '11' + Content-Type: + - application/octet-stream + If-None-Match: + - '*' + User-Agent: + - azsdk-python-storage-blob/12.0.0b4 Python/3.7.3 (Windows-10-10.0.17763-SP0) + x-ms-blob-type: + - BlockBlob + x-ms-client-request-id: + - 90179c70-f1e4-11e9-bab3-2816a845e8c6 + x-ms-date: + - Fri, 18 Oct 2019 20:19:18 GMT + x-ms-version: + - '2019-02-02' + method: PUT + uri: https://blobstoragename.blob.core.windows.net/containera687174a/blob3 + response: + body: + string: '' + headers: + Content-Length: + - '0' + Content-MD5: + - XrY7u+Ae7tCTyyK7j1rNww== + Date: + - Fri, 18 Oct 2019 20:19:17 GMT + ETag: + - '"0x8D7540873C0BD06"' + Last-Modified: + - Fri, 18 Oct 2019 20:19:17 GMT + Server: + - Windows-Azure-Blob/1.0 Microsoft-HTTPAPI/2.0 + x-ms-content-crc64: + - vo7q9sPVKY0= + x-ms-request-id: + - ecec2e87-401e-00ac-52f1-854597000000 + x-ms-request-server-encrypted: + - 'true' + x-ms-version: + - '2019-02-02' + status: + code: 201 + message: Created +- request: + body: null + headers: + Accept: + - '*/*' + Accept-Encoding: + - gzip, deflate + Connection: + - keep-alive + User-Agent: + - azsdk-python-storage-blob/12.0.0b4 Python/3.7.3 (Windows-10-10.0.17763-SP0) + x-ms-client-request-id: + - 9024aac8-f1e4-11e9-9bc4-2816a845e8c6 + x-ms-date: + - Fri, 18 Oct 2019 20:19:18 GMT + x-ms-version: + - '2019-02-02' + method: HEAD + uri: https://blobstoragename.blob.core.windows.net/containera687174a/blob1 + response: + body: + string: '' + headers: + Accept-Ranges: + - bytes + Content-Length: + - '11' + Content-MD5: + - XrY7u+Ae7tCTyyK7j1rNww== + Content-Type: + - application/octet-stream + Date: + - Fri, 18 Oct 2019 20:19:17 GMT + ETag: + - '"0x8D7540873A08507"' + Last-Modified: + - Fri, 18 Oct 2019 20:19:17 GMT + Server: + - Windows-Azure-Blob/1.0 Microsoft-HTTPAPI/2.0 + Vary: + - Origin + x-ms-access-tier: + - Hot + x-ms-access-tier-inferred: + - 'true' + x-ms-blob-type: + - BlockBlob + x-ms-creation-time: + - Fri, 18 Oct 2019 20:19:17 GMT + x-ms-lease-state: + - available + x-ms-lease-status: + - unlocked + x-ms-request-id: + - ecec2e93-401e-00ac-5ef1-854597000000 + x-ms-server-encrypted: + - 'true' + x-ms-version: + - '2019-02-02' + status: + code: 200 + message: OK +- request: + body: "--===============1052005317==\r\nContent-Type: application/http\r\nContent-Transfer-Encoding: + binary\r\nContent-ID: 0\r\n\r\nPUT /containera687174a/blob1?comp=tier HTTP/1.1\r\nContent-Length: + 0\r\nx-ms-access-tier: Archive\r\nx-ms-date: Fri, 18 Oct 2019 20:19:18 GMT\r\nx-ms-client-request-id: + 90317340-f1e4-11e9-a595-2816a845e8c6\r\nAuthorization: SharedKey blobstoragename:vq7juZFevGemkGSefkLU4Iz7jmC8HufbyzZ6ox6q3i4=\r\n\r\n\r\n--===============1052005317==\r\nContent-Type: + application/http\r\nContent-Transfer-Encoding: binary\r\nContent-ID: 1\r\n\r\nPUT + /containera687174a/blob2?comp=tier HTTP/1.1\r\nContent-Length: 0\r\nx-ms-access-tier: + Archive\r\nx-ms-date: Fri, 18 Oct 2019 20:19:18 GMT\r\nx-ms-client-request-id: + 90319a36-f1e4-11e9-ad1f-2816a845e8c6\r\nAuthorization: SharedKey blobstoragename:VkcxD8DN4JnrtPzHNlZqPolx8pqVkAr1EDHTT5cl0u0=\r\n\r\n\r\n--===============1052005317==\r\nContent-Type: + application/http\r\nContent-Transfer-Encoding: binary\r\nContent-ID: 2\r\n\r\nPUT + /containera687174a/blob3?comp=tier HTTP/1.1\r\nContent-Length: 0\r\nx-ms-access-tier: + Archive\r\nx-ms-date: Fri, 18 Oct 2019 20:19:18 GMT\r\nx-ms-client-request-id: + 90319a37-f1e4-11e9-afe5-2816a845e8c6\r\nAuthorization: SharedKey blobstoragename:hr/kuWH0BwXSaOhPZz8RTvMAqw74Os4mfbjju0luUic=\r\n\r\n\r\n--===============1052005317==--\r\n" + headers: + Accept: + - '*/*' + Accept-Encoding: + - gzip, deflate + Connection: + - keep-alive + Content-Length: + - '1227' + Content-Type: + - multipart/mixed; boundary================1052005317== + User-Agent: + - azsdk-python-storage-blob/12.0.0b4 Python/3.7.3 (Windows-10-10.0.17763-SP0) + x-ms-client-request-id: + - 9032360c-f1e4-11e9-a052-2816a845e8c6 + x-ms-date: + - Fri, 18 Oct 2019 20:19:18 GMT + x-ms-version: + - '2019-02-02' + method: POST + uri: https://blobstoragename.blob.core.windows.net/?comp=batch + response: + body: + string: "--batchresponse_23de09c3-8f30-4dbd-9229-d2da1cfadd42\r\nContent-Type: + application/http\r\nContent-ID: 0\r\n\r\nHTTP/1.1 200 OK\r\nx-ms-request-id: + ecec2ea0-401e-00ac-69f1-8545971e82e6\r\nx-ms-version: 2019-02-02\r\nServer: + Windows-Azure-Blob/1.0\r\n\r\n--batchresponse_23de09c3-8f30-4dbd-9229-d2da1cfadd42\r\nContent-Type: + application/http\r\nContent-ID: 1\r\n\r\nHTTP/1.1 200 OK\r\nx-ms-request-id: + ecec2ea0-401e-00ac-69f1-8545971e82e7\r\nx-ms-version: 2019-02-02\r\nServer: + Windows-Azure-Blob/1.0\r\n\r\n--batchresponse_23de09c3-8f30-4dbd-9229-d2da1cfadd42\r\nContent-Type: + application/http\r\nContent-ID: 2\r\n\r\nHTTP/1.1 200 OK\r\nx-ms-request-id: + ecec2ea0-401e-00ac-69f1-8545971e82e8\r\nx-ms-version: 2019-02-02\r\nServer: + Windows-Azure-Blob/1.0\r\n\r\n--batchresponse_23de09c3-8f30-4dbd-9229-d2da1cfadd42--" + headers: + Content-Type: + - multipart/mixed; boundary=batchresponse_23de09c3-8f30-4dbd-9229-d2da1cfadd42 + Date: + - Fri, 18 Oct 2019 20:19:17 GMT + Server: + - Windows-Azure-Blob/1.0 Microsoft-HTTPAPI/2.0 + Transfer-Encoding: + - chunked + x-ms-request-id: + - ecec2ea0-401e-00ac-69f1-854597000000 + x-ms-version: + - '2019-02-02' + status: + code: 202 + message: Accepted +- request: + body: null + headers: + Accept: + - '*/*' + Accept-Encoding: + - gzip, deflate + Connection: + - keep-alive + User-Agent: + - azsdk-python-storage-blob/12.0.0b4 Python/3.7.3 (Windows-10-10.0.17763-SP0) + x-ms-client-request-id: + - 90486e48-f1e4-11e9-b953-2816a845e8c6 + x-ms-date: + - Fri, 18 Oct 2019 20:19:18 GMT + x-ms-version: + - '2019-02-02' + method: HEAD + uri: https://blobstoragename.blob.core.windows.net/containera687174a/blob1 + response: + body: + string: '' + headers: + Accept-Ranges: + - bytes + Content-Length: + - '11' + Content-MD5: + - XrY7u+Ae7tCTyyK7j1rNww== + Content-Type: + - application/octet-stream + Date: + - Fri, 18 Oct 2019 20:19:17 GMT + ETag: + - '"0x8D7540873A08507"' + Last-Modified: + - Fri, 18 Oct 2019 20:19:17 GMT + Server: + - Windows-Azure-Blob/1.0 Microsoft-HTTPAPI/2.0 + Vary: + - Origin + x-ms-access-tier: + - Archive + x-ms-access-tier-change-time: + - Fri, 18 Oct 2019 20:19:17 GMT + x-ms-blob-type: + - BlockBlob + x-ms-creation-time: + - Fri, 18 Oct 2019 20:19:17 GMT + x-ms-lease-state: + - available + x-ms-lease-status: + - unlocked + x-ms-request-id: + - ecec2eba-401e-00ac-03f1-854597000000 + x-ms-server-encrypted: + - 'true' + x-ms-version: + - '2019-02-02' + status: + code: 200 + message: OK +- request: + body: "--===============1086790154==\r\nContent-Type: application/http\r\nContent-Transfer-Encoding: + binary\r\nContent-ID: 0\r\n\r\nDELETE /containera687174a/blob1? HTTP/1.1\r\nx-ms-date: + Fri, 18 Oct 2019 20:19:18 GMT\r\nx-ms-client-request-id: 905b4cb8-f1e4-11e9-9bb0-2816a845e8c6\r\nAuthorization: + SharedKey blobstoragename:mt2cG+LKvp0+SzJc6jTyuhingpZNZ25plOsgqh9lDuM=\r\n\r\n\r\n--===============1086790154==\r\nContent-Type: + application/http\r\nContent-Transfer-Encoding: binary\r\nContent-ID: 1\r\n\r\nDELETE + /containera687174a/blob2? HTTP/1.1\r\nx-ms-date: Fri, 18 Oct 2019 20:19:18 GMT\r\nx-ms-client-request-id: + 905b4cb9-f1e4-11e9-8c3b-2816a845e8c6\r\nAuthorization: SharedKey blobstoragename:uyp9JyMQj9LKzqxPTRcpaEfSZex8uj+xYOaMimZzHtQ=\r\n\r\n\r\n--===============1086790154==\r\nContent-Type: + application/http\r\nContent-Transfer-Encoding: binary\r\nContent-ID: 2\r\n\r\nDELETE + /containera687174a/blob3? HTTP/1.1\r\nx-ms-date: Fri, 18 Oct 2019 20:19:18 GMT\r\nx-ms-client-request-id: + 905b73b4-f1e4-11e9-a5db-2816a845e8c6\r\nAuthorization: SharedKey blobstoragename:u60E25Iavq2SrvtTCkaxh2tpzFcU6MMJzi9jX2EnuZY=\r\n\r\n\r\n--===============1086790154==--\r\n" + headers: + Accept: + - '*/*' + Accept-Encoding: + - gzip, deflate + Connection: + - keep-alive + Content-Length: + - '1071' + Content-Type: + - multipart/mixed; boundary================1086790154== + User-Agent: + - azsdk-python-storage-blob/12.0.0b4 Python/3.7.3 (Windows-10-10.0.17763-SP0) + x-ms-client-request-id: + - 905bc2ba-f1e4-11e9-a0c4-2816a845e8c6 + x-ms-date: + - Fri, 18 Oct 2019 20:19:18 GMT + x-ms-version: + - '2019-02-02' + method: POST + uri: https://blobstoragename.blob.core.windows.net/?comp=batch + response: + body: + string: "--batchresponse_63f785fb-e738-4873-84ba-bc205f3b889a\r\nContent-Type: + application/http\r\nContent-ID: 0\r\n\r\nHTTP/1.1 202 Accepted\r\nx-ms-delete-type-permanent: + true\r\nx-ms-request-id: ecec2ecb-401e-00ac-14f1-8545971e82ea\r\nx-ms-version: + 2019-02-02\r\nServer: Windows-Azure-Blob/1.0\r\n\r\n--batchresponse_63f785fb-e738-4873-84ba-bc205f3b889a\r\nContent-Type: + application/http\r\nContent-ID: 1\r\n\r\nHTTP/1.1 202 Accepted\r\nx-ms-delete-type-permanent: + true\r\nx-ms-request-id: ecec2ecb-401e-00ac-14f1-8545971e82eb\r\nx-ms-version: + 2019-02-02\r\nServer: Windows-Azure-Blob/1.0\r\n\r\n--batchresponse_63f785fb-e738-4873-84ba-bc205f3b889a\r\nContent-Type: + application/http\r\nContent-ID: 2\r\n\r\nHTTP/1.1 202 Accepted\r\nx-ms-delete-type-permanent: + true\r\nx-ms-request-id: ecec2ecb-401e-00ac-14f1-8545971e82ec\r\nx-ms-version: + 2019-02-02\r\nServer: Windows-Azure-Blob/1.0\r\n\r\n--batchresponse_63f785fb-e738-4873-84ba-bc205f3b889a--" + headers: + Content-Type: + - multipart/mixed; boundary=batchresponse_63f785fb-e738-4873-84ba-bc205f3b889a + Date: + - Fri, 18 Oct 2019 20:19:17 GMT + Server: + - Windows-Azure-Blob/1.0 Microsoft-HTTPAPI/2.0 + Transfer-Encoding: + - chunked + x-ms-request-id: + - ecec2ecb-401e-00ac-14f1-854597000000 + x-ms-version: + - '2019-02-02' + status: + code: 202 + message: Accepted +- request: + body: hello world + headers: + Accept: + - '*/*' + Accept-Encoding: + - gzip, deflate + Connection: + - keep-alive + Content-Length: + - '11' + Content-Type: + - application/octet-stream + If-None-Match: + - '*' + User-Agent: + - azsdk-python-storage-blob/12.0.0b4 Python/3.7.3 (Windows-10-10.0.17763-SP0) + x-ms-blob-type: + - BlockBlob + x-ms-client-request-id: + - 906a85b6-f1e4-11e9-9b5c-2816a845e8c6 + x-ms-date: + - Fri, 18 Oct 2019 20:19:18 GMT + x-ms-version: + - '2019-02-02' + method: PUT + uri: https://blobstoragename.blob.core.windows.net/containera687174a/blob1 + response: + body: + string: '' + headers: + Content-Length: + - '0' + Content-MD5: + - XrY7u+Ae7tCTyyK7j1rNww== + Date: + - Fri, 18 Oct 2019 20:19:17 GMT + ETag: + - '"0x8D7540874157C02"' + Last-Modified: + - Fri, 18 Oct 2019 20:19:18 GMT + Server: + - Windows-Azure-Blob/1.0 Microsoft-HTTPAPI/2.0 + x-ms-content-crc64: + - vo7q9sPVKY0= + x-ms-request-id: + - ecec2edc-401e-00ac-22f1-854597000000 + x-ms-request-server-encrypted: + - 'true' + x-ms-version: + - '2019-02-02' + status: + code: 201 + message: Created +- request: + body: hello world + headers: + Accept: + - '*/*' + Accept-Encoding: + - gzip, deflate + Connection: + - keep-alive + Content-Length: + - '11' + Content-Type: + - application/octet-stream + If-None-Match: + - '*' + User-Agent: + - azsdk-python-storage-blob/12.0.0b4 Python/3.7.3 (Windows-10-10.0.17763-SP0) + x-ms-blob-type: + - BlockBlob + x-ms-client-request-id: + - 907af5ac-f1e4-11e9-a783-2816a845e8c6 + x-ms-date: + - Fri, 18 Oct 2019 20:19:19 GMT + x-ms-version: + - '2019-02-02' + method: PUT + uri: https://blobstoragename.blob.core.windows.net/containera687174a/blob2 + response: + body: + string: '' + headers: + Content-Length: + - '0' + Content-MD5: + - XrY7u+Ae7tCTyyK7j1rNww== + Date: + - Fri, 18 Oct 2019 20:19:17 GMT + ETag: + - '"0x8D7540874255D5B"' + Last-Modified: + - Fri, 18 Oct 2019 20:19:18 GMT + Server: + - Windows-Azure-Blob/1.0 Microsoft-HTTPAPI/2.0 + x-ms-content-crc64: + - vo7q9sPVKY0= + x-ms-request-id: + - ecec2f01-401e-00ac-42f1-854597000000 + x-ms-request-server-encrypted: + - 'true' + x-ms-version: + - '2019-02-02' + status: + code: 201 + message: Created +- request: + body: hello world + headers: + Accept: + - '*/*' + Accept-Encoding: + - gzip, deflate + Connection: + - keep-alive + Content-Length: + - '11' + Content-Type: + - application/octet-stream + If-None-Match: + - '*' + User-Agent: + - azsdk-python-storage-blob/12.0.0b4 Python/3.7.3 (Windows-10-10.0.17763-SP0) + x-ms-blob-type: + - BlockBlob + x-ms-client-request-id: + - 908aa274-f1e4-11e9-952d-2816a845e8c6 + x-ms-date: + - Fri, 18 Oct 2019 20:19:19 GMT + x-ms-version: + - '2019-02-02' + method: PUT + uri: https://blobstoragename.blob.core.windows.net/containera687174a/blob3 + response: + body: + string: '' + headers: + Content-Length: + - '0' + Content-MD5: + - XrY7u+Ae7tCTyyK7j1rNww== + Date: + - Fri, 18 Oct 2019 20:19:17 GMT + ETag: + - '"0x8D754087434A260"' + Last-Modified: + - Fri, 18 Oct 2019 20:19:18 GMT + Server: + - Windows-Azure-Blob/1.0 Microsoft-HTTPAPI/2.0 + x-ms-content-crc64: + - vo7q9sPVKY0= + x-ms-request-id: + - ecec2f22-401e-00ac-5bf1-854597000000 + x-ms-request-server-encrypted: + - 'true' + x-ms-version: + - '2019-02-02' + status: + code: 201 + message: Created +- request: + body: null + headers: + Accept: + - '*/*' + Accept-Encoding: + - gzip, deflate + Connection: + - keep-alive + User-Agent: + - azsdk-python-storage-blob/12.0.0b4 Python/3.7.3 (Windows-10-10.0.17763-SP0) + x-ms-client-request-id: + - 9099179e-f1e4-11e9-9d73-2816a845e8c6 + x-ms-date: + - Fri, 18 Oct 2019 20:19:19 GMT + x-ms-version: + - '2019-02-02' + method: HEAD + uri: https://blobstoragename.blob.core.windows.net/containera687174a/blob1 + response: + body: + string: '' + headers: + Accept-Ranges: + - bytes + Content-Length: + - '11' + Content-MD5: + - XrY7u+Ae7tCTyyK7j1rNww== + Content-Type: + - application/octet-stream + Date: + - Fri, 18 Oct 2019 20:19:18 GMT + ETag: + - '"0x8D7540874157C02"' + Last-Modified: + - Fri, 18 Oct 2019 20:19:18 GMT + Server: + - Windows-Azure-Blob/1.0 Microsoft-HTTPAPI/2.0 + Vary: + - Origin + x-ms-access-tier: + - Hot + x-ms-access-tier-inferred: + - 'true' + x-ms-blob-type: + - BlockBlob + x-ms-creation-time: + - Fri, 18 Oct 2019 20:19:18 GMT + x-ms-lease-state: + - available + x-ms-lease-status: + - unlocked + x-ms-request-id: + - ecec2f3c-401e-00ac-75f1-854597000000 + x-ms-server-encrypted: + - 'true' + x-ms-version: + - '2019-02-02' + status: + code: 200 + message: OK +- request: + body: "--===============0999079139==\r\nContent-Type: application/http\r\nContent-Transfer-Encoding: + binary\r\nContent-ID: 0\r\n\r\nPUT /containera687174a/blob1?comp=tier HTTP/1.1\r\nContent-Length: + 0\r\nx-ms-access-tier: Cool\r\nx-ms-date: Fri, 18 Oct 2019 20:19:19 GMT\r\nx-ms-client-request-id: + 90ac919c-f1e4-11e9-8ffc-2816a845e8c6\r\nAuthorization: SharedKey blobstoragename:r5bl9p+rGMNvmpFGBFJKllNOM7sKDgYCXVy4TTdmTfY=\r\n\r\n\r\n--===============0999079139==\r\nContent-Type: + application/http\r\nContent-Transfer-Encoding: binary\r\nContent-ID: 1\r\n\r\nPUT + /containera687174a/blob2?comp=tier HTTP/1.1\r\nContent-Length: 0\r\nx-ms-access-tier: + Cool\r\nx-ms-date: Fri, 18 Oct 2019 20:19:19 GMT\r\nx-ms-client-request-id: + 90ac919d-f1e4-11e9-bdf7-2816a845e8c6\r\nAuthorization: SharedKey blobstoragename:yQaYYKT/5U9OCtXGmbklNapMyw49cY8SLyz3RTxg0Eo=\r\n\r\n\r\n--===============0999079139==\r\nContent-Type: + application/http\r\nContent-Transfer-Encoding: binary\r\nContent-ID: 2\r\n\r\nPUT + /containera687174a/blob3?comp=tier HTTP/1.1\r\nContent-Length: 0\r\nx-ms-access-tier: + Cool\r\nx-ms-date: Fri, 18 Oct 2019 20:19:19 GMT\r\nx-ms-client-request-id: + 90acb778-f1e4-11e9-be87-2816a845e8c6\r\nAuthorization: SharedKey blobstoragename:/gwDYaV4RoefCNZSJCzhUK+buVQoq4P89CeaPBQG/Tc=\r\n\r\n\r\n--===============0999079139==--\r\n" + headers: + Accept: + - '*/*' + Accept-Encoding: + - gzip, deflate + Connection: + - keep-alive + Content-Length: + - '1218' + Content-Type: + - multipart/mixed; boundary================0999079139== + User-Agent: + - azsdk-python-storage-blob/12.0.0b4 Python/3.7.3 (Windows-10-10.0.17763-SP0) + x-ms-client-request-id: + - 90ad534c-f1e4-11e9-999d-2816a845e8c6 + x-ms-date: + - Fri, 18 Oct 2019 20:19:19 GMT + x-ms-version: + - '2019-02-02' + method: POST + uri: https://blobstoragename.blob.core.windows.net/?comp=batch + response: + body: + string: "--batchresponse_f6f2b6a1-841f-43ea-8c8a-1b9f4c40323b\r\nContent-Type: + application/http\r\nContent-ID: 0\r\n\r\nHTTP/1.1 200 OK\r\nx-ms-request-id: + ecec2f54-401e-00ac-0df1-8545971e82f8\r\nx-ms-version: 2019-02-02\r\nServer: + Windows-Azure-Blob/1.0\r\n\r\n--batchresponse_f6f2b6a1-841f-43ea-8c8a-1b9f4c40323b\r\nContent-Type: + application/http\r\nContent-ID: 1\r\n\r\nHTTP/1.1 200 OK\r\nx-ms-request-id: + ecec2f54-401e-00ac-0df1-8545971e82f9\r\nx-ms-version: 2019-02-02\r\nServer: + Windows-Azure-Blob/1.0\r\n\r\n--batchresponse_f6f2b6a1-841f-43ea-8c8a-1b9f4c40323b\r\nContent-Type: + application/http\r\nContent-ID: 2\r\n\r\nHTTP/1.1 200 OK\r\nx-ms-request-id: + ecec2f54-401e-00ac-0df1-8545971e82fa\r\nx-ms-version: 2019-02-02\r\nServer: + Windows-Azure-Blob/1.0\r\n\r\n--batchresponse_f6f2b6a1-841f-43ea-8c8a-1b9f4c40323b--" + headers: + Content-Type: + - multipart/mixed; boundary=batchresponse_f6f2b6a1-841f-43ea-8c8a-1b9f4c40323b + Date: + - Fri, 18 Oct 2019 20:19:18 GMT + Server: + - Windows-Azure-Blob/1.0 Microsoft-HTTPAPI/2.0 + Transfer-Encoding: + - chunked + x-ms-request-id: + - ecec2f54-401e-00ac-0df1-854597000000 + x-ms-version: + - '2019-02-02' + status: + code: 202 + message: Accepted +- request: + body: null + headers: + Accept: + - '*/*' + Accept-Encoding: + - gzip, deflate + Connection: + - keep-alive + User-Agent: + - azsdk-python-storage-blob/12.0.0b4 Python/3.7.3 (Windows-10-10.0.17763-SP0) + x-ms-client-request-id: + - 90bb5368-f1e4-11e9-8357-2816a845e8c6 + x-ms-date: + - Fri, 18 Oct 2019 20:19:19 GMT + x-ms-version: + - '2019-02-02' + method: HEAD + uri: https://blobstoragename.blob.core.windows.net/containera687174a/blob1 + response: + body: + string: '' + headers: + Accept-Ranges: + - bytes + Content-Length: + - '11' + Content-MD5: + - XrY7u+Ae7tCTyyK7j1rNww== + Content-Type: + - application/octet-stream + Date: + - Fri, 18 Oct 2019 20:19:18 GMT + ETag: + - '"0x8D7540874157C02"' + Last-Modified: + - Fri, 18 Oct 2019 20:19:18 GMT + Server: + - Windows-Azure-Blob/1.0 Microsoft-HTTPAPI/2.0 + Vary: + - Origin + x-ms-access-tier: + - Cool + x-ms-access-tier-change-time: + - Fri, 18 Oct 2019 20:19:18 GMT + x-ms-blob-type: + - BlockBlob + x-ms-creation-time: + - Fri, 18 Oct 2019 20:19:18 GMT + x-ms-lease-state: + - available + x-ms-lease-status: + - unlocked + x-ms-request-id: + - ecec2f72-401e-00ac-2bf1-854597000000 + x-ms-server-encrypted: + - 'true' + x-ms-version: + - '2019-02-02' + status: + code: 200 + message: OK +- request: + body: "--===============1854079213==\r\nContent-Type: application/http\r\nContent-Transfer-Encoding: + binary\r\nContent-ID: 0\r\n\r\nDELETE /containera687174a/blob1? HTTP/1.1\r\nx-ms-date: + Fri, 18 Oct 2019 20:19:19 GMT\r\nx-ms-client-request-id: 90c8b898-f1e4-11e9-8fcc-2816a845e8c6\r\nAuthorization: + SharedKey blobstoragename:RR3XJa2KBJs7mDxcxA5RjVRYmNc4PRhaMfLqhCD+WkE=\r\n\r\n\r\n--===============1854079213==\r\nContent-Type: + application/http\r\nContent-Transfer-Encoding: binary\r\nContent-ID: 1\r\n\r\nDELETE + /containera687174a/blob2? HTTP/1.1\r\nx-ms-date: Fri, 18 Oct 2019 20:19:19 GMT\r\nx-ms-client-request-id: + 90c8dfdc-f1e4-11e9-b0b3-2816a845e8c6\r\nAuthorization: SharedKey blobstoragename:58DuGCd5X8NiiclgOfCtW3SnnZGCXnjGJ6hmMPbqdgY=\r\n\r\n\r\n--===============1854079213==\r\nContent-Type: + application/http\r\nContent-Transfer-Encoding: binary\r\nContent-ID: 2\r\n\r\nDELETE + /containera687174a/blob3? HTTP/1.1\r\nx-ms-date: Fri, 18 Oct 2019 20:19:19 GMT\r\nx-ms-client-request-id: + 90c8dfdd-f1e4-11e9-b12f-2816a845e8c6\r\nAuthorization: SharedKey blobstoragename:JbeAwprDYtsDzTIJjqi+zT5M9ErImhPHUmYrI9FLTUU=\r\n\r\n\r\n--===============1854079213==--\r\n" + headers: + Accept: + - '*/*' + Accept-Encoding: + - gzip, deflate + Connection: + - keep-alive + Content-Length: + - '1071' + Content-Type: + - multipart/mixed; boundary================1854079213== + User-Agent: + - azsdk-python-storage-blob/12.0.0b4 Python/3.7.3 (Windows-10-10.0.17763-SP0) + x-ms-client-request-id: + - 90c95458-f1e4-11e9-89ea-2816a845e8c6 + x-ms-date: + - Fri, 18 Oct 2019 20:19:19 GMT + x-ms-version: + - '2019-02-02' + method: POST + uri: https://blobstoragename.blob.core.windows.net/?comp=batch + response: + body: + string: "--batchresponse_f0e0730a-94eb-4ec3-b0ea-6b6f76cdf756\r\nContent-Type: + application/http\r\nContent-ID: 0\r\n\r\nHTTP/1.1 202 Accepted\r\nx-ms-delete-type-permanent: + true\r\nx-ms-request-id: ecec2f84-401e-00ac-3df1-8545971e82fd\r\nx-ms-version: + 2019-02-02\r\nServer: Windows-Azure-Blob/1.0\r\n\r\n--batchresponse_f0e0730a-94eb-4ec3-b0ea-6b6f76cdf756\r\nContent-Type: + application/http\r\nContent-ID: 1\r\n\r\nHTTP/1.1 202 Accepted\r\nx-ms-delete-type-permanent: + true\r\nx-ms-request-id: ecec2f84-401e-00ac-3df1-8545971e82fe\r\nx-ms-version: + 2019-02-02\r\nServer: Windows-Azure-Blob/1.0\r\n\r\n--batchresponse_f0e0730a-94eb-4ec3-b0ea-6b6f76cdf756\r\nContent-Type: + application/http\r\nContent-ID: 2\r\n\r\nHTTP/1.1 202 Accepted\r\nx-ms-delete-type-permanent: + true\r\nx-ms-request-id: ecec2f84-401e-00ac-3df1-8545971e82ff\r\nx-ms-version: + 2019-02-02\r\nServer: Windows-Azure-Blob/1.0\r\n\r\n--batchresponse_f0e0730a-94eb-4ec3-b0ea-6b6f76cdf756--" + headers: + Content-Type: + - multipart/mixed; boundary=batchresponse_f0e0730a-94eb-4ec3-b0ea-6b6f76cdf756 + Date: + - Fri, 18 Oct 2019 20:19:18 GMT + Server: + - Windows-Azure-Blob/1.0 Microsoft-HTTPAPI/2.0 + Transfer-Encoding: + - chunked + x-ms-request-id: + - ecec2f84-401e-00ac-3df1-854597000000 + x-ms-version: + - '2019-02-02' + status: + code: 202 + message: Accepted +- request: + body: hello world + headers: + Accept: + - '*/*' + Accept-Encoding: + - gzip, deflate + Connection: + - keep-alive + Content-Length: + - '11' + Content-Type: + - application/octet-stream + If-None-Match: + - '*' + User-Agent: + - azsdk-python-storage-blob/12.0.0b4 Python/3.7.3 (Windows-10-10.0.17763-SP0) + x-ms-blob-type: + - BlockBlob + x-ms-client-request-id: + - 90d7efac-f1e4-11e9-b8ba-2816a845e8c6 + x-ms-date: + - Fri, 18 Oct 2019 20:19:19 GMT + x-ms-version: + - '2019-02-02' + method: PUT + uri: https://blobstoragename.blob.core.windows.net/containera687174a/blob1 + response: + body: + string: '' + headers: + Content-Length: + - '0' + Content-MD5: + - XrY7u+Ae7tCTyyK7j1rNww== + Date: + - Fri, 18 Oct 2019 20:19:18 GMT + ETag: + - '"0x8D754087484575B"' + Last-Modified: + - Fri, 18 Oct 2019 20:19:18 GMT + Server: + - Windows-Azure-Blob/1.0 Microsoft-HTTPAPI/2.0 + x-ms-content-crc64: + - vo7q9sPVKY0= + x-ms-request-id: + - ecec2fa1-401e-00ac-54f1-854597000000 + x-ms-request-server-encrypted: + - 'true' + x-ms-version: + - '2019-02-02' + status: + code: 201 + message: Created +- request: + body: hello world + headers: + Accept: + - '*/*' + Accept-Encoding: + - gzip, deflate + Connection: + - keep-alive + Content-Length: + - '11' + Content-Type: + - application/octet-stream + If-None-Match: + - '*' + User-Agent: + - azsdk-python-storage-blob/12.0.0b4 Python/3.7.3 (Windows-10-10.0.17763-SP0) + x-ms-blob-type: + - BlockBlob + x-ms-client-request-id: + - 90e997fa-f1e4-11e9-b2aa-2816a845e8c6 + x-ms-date: + - Fri, 18 Oct 2019 20:19:19 GMT + x-ms-version: + - '2019-02-02' + method: PUT + uri: https://blobstoragename.blob.core.windows.net/containera687174a/blob2 + response: + body: + string: '' + headers: + Content-Length: + - '0' + Content-MD5: + - XrY7u+Ae7tCTyyK7j1rNww== + Date: + - Fri, 18 Oct 2019 20:19:18 GMT + ETag: + - '"0x8D7540874968315"' + Last-Modified: + - Fri, 18 Oct 2019 20:19:18 GMT + Server: + - Windows-Azure-Blob/1.0 Microsoft-HTTPAPI/2.0 + x-ms-content-crc64: + - vo7q9sPVKY0= + x-ms-request-id: + - ecec2fbe-401e-00ac-6cf1-854597000000 + x-ms-request-server-encrypted: + - 'true' + x-ms-version: + - '2019-02-02' + status: + code: 201 + message: Created +- request: + body: hello world + headers: + Accept: + - '*/*' + Accept-Encoding: + - gzip, deflate + Connection: + - keep-alive + Content-Length: + - '11' + Content-Type: + - application/octet-stream + If-None-Match: + - '*' + User-Agent: + - azsdk-python-storage-blob/12.0.0b4 Python/3.7.3 (Windows-10-10.0.17763-SP0) + x-ms-blob-type: + - BlockBlob + x-ms-client-request-id: + - 90fe4aa4-f1e4-11e9-941c-2816a845e8c6 + x-ms-date: + - Fri, 18 Oct 2019 20:19:19 GMT + x-ms-version: + - '2019-02-02' + method: PUT + uri: https://blobstoragename.blob.core.windows.net/containera687174a/blob3 + response: + body: + string: '' + headers: + Content-Length: + - '0' + Content-MD5: + - XrY7u+Ae7tCTyyK7j1rNww== + Date: + - Fri, 18 Oct 2019 20:19:18 GMT + ETag: + - '"0x8D7540874AAF922"' + Last-Modified: + - Fri, 18 Oct 2019 20:19:19 GMT + Server: + - Windows-Azure-Blob/1.0 Microsoft-HTTPAPI/2.0 + x-ms-content-crc64: + - vo7q9sPVKY0= + x-ms-request-id: + - ecec2fda-401e-00ac-05f1-854597000000 + x-ms-request-server-encrypted: + - 'true' + x-ms-version: + - '2019-02-02' + status: + code: 201 + message: Created +- request: + body: null + headers: + Accept: + - '*/*' + Accept-Encoding: + - gzip, deflate + Connection: + - keep-alive + User-Agent: + - azsdk-python-storage-blob/12.0.0b4 Python/3.7.3 (Windows-10-10.0.17763-SP0) + x-ms-client-request-id: + - 910f5646-f1e4-11e9-8d05-2816a845e8c6 + x-ms-date: + - Fri, 18 Oct 2019 20:19:20 GMT + x-ms-version: + - '2019-02-02' + method: HEAD + uri: https://blobstoragename.blob.core.windows.net/containera687174a/blob1 + response: + body: + string: '' + headers: + Accept-Ranges: + - bytes + Content-Length: + - '11' + Content-MD5: + - XrY7u+Ae7tCTyyK7j1rNww== + Content-Type: + - application/octet-stream + Date: + - Fri, 18 Oct 2019 20:19:18 GMT + ETag: + - '"0x8D754087484575B"' + Last-Modified: + - Fri, 18 Oct 2019 20:19:18 GMT + Server: + - Windows-Azure-Blob/1.0 Microsoft-HTTPAPI/2.0 + Vary: + - Origin + x-ms-access-tier: + - Hot + x-ms-access-tier-inferred: + - 'true' + x-ms-blob-type: + - BlockBlob + x-ms-creation-time: + - Fri, 18 Oct 2019 20:19:18 GMT + x-ms-lease-state: + - available + x-ms-lease-status: + - unlocked + x-ms-request-id: + - ecec2ffd-401e-00ac-24f1-854597000000 + x-ms-server-encrypted: + - 'true' + x-ms-version: + - '2019-02-02' + status: + code: 200 + message: OK +- request: + body: "--===============0629394972==\r\nContent-Type: application/http\r\nContent-Transfer-Encoding: + binary\r\nContent-ID: 0\r\n\r\nPUT /containera687174a/blob1?comp=tier HTTP/1.1\r\nContent-Length: + 0\r\nx-ms-access-tier: Hot\r\nx-ms-date: Fri, 18 Oct 2019 20:19:20 GMT\r\nx-ms-client-request-id: + 91212450-f1e4-11e9-9956-2816a845e8c6\r\nAuthorization: SharedKey blobstoragename:acpxFhstBPaaYVbm5ePsCpnJuNlLQy8VfHmQHPlws6o=\r\n\r\n\r\n--===============0629394972==\r\nContent-Type: + application/http\r\nContent-Transfer-Encoding: binary\r\nContent-ID: 1\r\n\r\nPUT + /containera687174a/blob2?comp=tier HTTP/1.1\r\nContent-Length: 0\r\nx-ms-access-tier: + Hot\r\nx-ms-date: Fri, 18 Oct 2019 20:19:20 GMT\r\nx-ms-client-request-id: 9121498a-f1e4-11e9-ba54-2816a845e8c6\r\nAuthorization: + SharedKey blobstoragename:gpo+rcVAcYooQ8aAOIhNUkZBE4E1Z/e0XdnbMAHqgtg=\r\n\r\n\r\n--===============0629394972==\r\nContent-Type: + application/http\r\nContent-Transfer-Encoding: binary\r\nContent-ID: 2\r\n\r\nPUT + /containera687174a/blob3?comp=tier HTTP/1.1\r\nContent-Length: 0\r\nx-ms-access-tier: + Hot\r\nx-ms-date: Fri, 18 Oct 2019 20:19:20 GMT\r\nx-ms-client-request-id: 91219782-f1e4-11e9-a135-2816a845e8c6\r\nAuthorization: + SharedKey blobstoragename:POirm154RbAd7rbIPdsKeUoOOOBTsJMZaGNg6cqnp+g=\r\n\r\n\r\n--===============0629394972==--\r\n" + headers: + Accept: + - '*/*' + Accept-Encoding: + - gzip, deflate + Connection: + - keep-alive + Content-Length: + - '1215' + Content-Type: + - multipart/mixed; boundary================0629394972== + User-Agent: + - azsdk-python-storage-blob/12.0.0b4 Python/3.7.3 (Windows-10-10.0.17763-SP0) + x-ms-client-request-id: + - 9122a99c-f1e4-11e9-a4f7-2816a845e8c6 + x-ms-date: + - Fri, 18 Oct 2019 20:19:20 GMT + x-ms-version: + - '2019-02-02' + method: POST + uri: https://blobstoragename.blob.core.windows.net/?comp=batch + response: + body: + string: "--batchresponse_72dd1985-388e-4759-a363-4b065df27ab4\r\nContent-Type: + application/http\r\nContent-ID: 0\r\n\r\nHTTP/1.1 200 OK\r\nx-ms-request-id: + ecec3019-401e-00ac-3cf1-8545971e830d\r\nx-ms-version: 2019-02-02\r\nServer: + Windows-Azure-Blob/1.0\r\n\r\n--batchresponse_72dd1985-388e-4759-a363-4b065df27ab4\r\nContent-Type: + application/http\r\nContent-ID: 1\r\n\r\nHTTP/1.1 200 OK\r\nx-ms-request-id: + ecec3019-401e-00ac-3cf1-8545971e830e\r\nx-ms-version: 2019-02-02\r\nServer: + Windows-Azure-Blob/1.0\r\n\r\n--batchresponse_72dd1985-388e-4759-a363-4b065df27ab4\r\nContent-Type: + application/http\r\nContent-ID: 2\r\n\r\nHTTP/1.1 200 OK\r\nx-ms-request-id: + ecec3019-401e-00ac-3cf1-8545971e830f\r\nx-ms-version: 2019-02-02\r\nServer: + Windows-Azure-Blob/1.0\r\n\r\n--batchresponse_72dd1985-388e-4759-a363-4b065df27ab4--" + headers: + Content-Type: + - multipart/mixed; boundary=batchresponse_72dd1985-388e-4759-a363-4b065df27ab4 + Date: + - Fri, 18 Oct 2019 20:19:19 GMT + Server: + - Windows-Azure-Blob/1.0 Microsoft-HTTPAPI/2.0 + Transfer-Encoding: + - chunked + x-ms-request-id: + - ecec3019-401e-00ac-3cf1-854597000000 + x-ms-version: + - '2019-02-02' + status: + code: 202 + message: Accepted +- request: + body: null + headers: + Accept: + - '*/*' + Accept-Encoding: + - gzip, deflate + Connection: + - keep-alive + User-Agent: + - azsdk-python-storage-blob/12.0.0b4 Python/3.7.3 (Windows-10-10.0.17763-SP0) + x-ms-client-request-id: + - 913670a2-f1e4-11e9-a56c-2816a845e8c6 + x-ms-date: + - Fri, 18 Oct 2019 20:19:20 GMT + x-ms-version: + - '2019-02-02' + method: HEAD + uri: https://blobstoragename.blob.core.windows.net/containera687174a/blob1 + response: + body: + string: '' + headers: + Accept-Ranges: + - bytes + Content-Length: + - '11' + Content-MD5: + - XrY7u+Ae7tCTyyK7j1rNww== + Content-Type: + - application/octet-stream + Date: + - Fri, 18 Oct 2019 20:19:19 GMT + ETag: + - '"0x8D754087484575B"' + Last-Modified: + - Fri, 18 Oct 2019 20:19:18 GMT + Server: + - Windows-Azure-Blob/1.0 Microsoft-HTTPAPI/2.0 + Vary: + - Origin + x-ms-access-tier: + - Hot + x-ms-access-tier-change-time: + - Fri, 18 Oct 2019 20:19:19 GMT + x-ms-blob-type: + - BlockBlob + x-ms-creation-time: + - Fri, 18 Oct 2019 20:19:18 GMT + x-ms-lease-state: + - available + x-ms-lease-status: + - unlocked + x-ms-request-id: + - ecec302f-401e-00ac-50f1-854597000000 + x-ms-server-encrypted: + - 'true' + x-ms-version: + - '2019-02-02' + status: + code: 200 + message: OK +- request: + body: "--===============1661563175==\r\nContent-Type: application/http\r\nContent-Transfer-Encoding: + binary\r\nContent-ID: 0\r\n\r\nDELETE /containera687174a/blob1? HTTP/1.1\r\nx-ms-date: + Fri, 18 Oct 2019 20:19:20 GMT\r\nx-ms-client-request-id: 9145a88c-f1e4-11e9-a308-2816a845e8c6\r\nAuthorization: + SharedKey blobstoragename:0wbL5V8uKrEl8X3RfNqNB5WsKkkjclOZYM95YgLTjNs=\r\n\r\n\r\n--===============1661563175==\r\nContent-Type: + application/http\r\nContent-Transfer-Encoding: binary\r\nContent-ID: 1\r\n\r\nDELETE + /containera687174a/blob2? HTTP/1.1\r\nx-ms-date: Fri, 18 Oct 2019 20:19:20 GMT\r\nx-ms-client-request-id: + 9145a88d-f1e4-11e9-907e-2816a845e8c6\r\nAuthorization: SharedKey blobstoragename:5FdJIo19saLwW61FaClyjDeu5THyAMA9TtjSXnRkB8g=\r\n\r\n\r\n--===============1661563175==\r\nContent-Type: + application/http\r\nContent-Transfer-Encoding: binary\r\nContent-ID: 2\r\n\r\nDELETE + /containera687174a/blob3? HTTP/1.1\r\nx-ms-date: Fri, 18 Oct 2019 20:19:20 GMT\r\nx-ms-client-request-id: + 9145cf6c-f1e4-11e9-9b09-2816a845e8c6\r\nAuthorization: SharedKey blobstoragename:yiZbducz0Yc8NQ5jj6wHHZA68BbCKDuKplTtmqILK8E=\r\n\r\n\r\n--===============1661563175==--\r\n" + headers: + Accept: + - '*/*' + Accept-Encoding: + - gzip, deflate + Connection: + - keep-alive + Content-Length: + - '1071' + Content-Type: + - multipart/mixed; boundary================1661563175== + User-Agent: + - azsdk-python-storage-blob/12.0.0b4 Python/3.7.3 (Windows-10-10.0.17763-SP0) + x-ms-client-request-id: + - 9146445a-f1e4-11e9-9b59-2816a845e8c6 + x-ms-date: + - Fri, 18 Oct 2019 20:19:20 GMT + x-ms-version: + - '2019-02-02' + method: POST + uri: https://blobstoragename.blob.core.windows.net/?comp=batch + response: + body: + string: "--batchresponse_661338ce-5585-4f50-9aae-72a108ff5809\r\nContent-Type: + application/http\r\nContent-ID: 0\r\n\r\nHTTP/1.1 202 Accepted\r\nx-ms-delete-type-permanent: + true\r\nx-ms-request-id: ecec3042-401e-00ac-62f1-8545971e8311\r\nx-ms-version: + 2019-02-02\r\nServer: Windows-Azure-Blob/1.0\r\n\r\n--batchresponse_661338ce-5585-4f50-9aae-72a108ff5809\r\nContent-Type: + application/http\r\nContent-ID: 1\r\n\r\nHTTP/1.1 202 Accepted\r\nx-ms-delete-type-permanent: + true\r\nx-ms-request-id: ecec3042-401e-00ac-62f1-8545971e8312\r\nx-ms-version: + 2019-02-02\r\nServer: Windows-Azure-Blob/1.0\r\n\r\n--batchresponse_661338ce-5585-4f50-9aae-72a108ff5809\r\nContent-Type: + application/http\r\nContent-ID: 2\r\n\r\nHTTP/1.1 202 Accepted\r\nx-ms-delete-type-permanent: + true\r\nx-ms-request-id: ecec3042-401e-00ac-62f1-8545971e8313\r\nx-ms-version: + 2019-02-02\r\nServer: Windows-Azure-Blob/1.0\r\n\r\n--batchresponse_661338ce-5585-4f50-9aae-72a108ff5809--" + headers: + Content-Type: + - multipart/mixed; boundary=batchresponse_661338ce-5585-4f50-9aae-72a108ff5809 + Date: + - Fri, 18 Oct 2019 20:19:19 GMT + Server: + - Windows-Azure-Blob/1.0 Microsoft-HTTPAPI/2.0 + Transfer-Encoding: + - chunked + x-ms-request-id: + - ecec3042-401e-00ac-62f1-854597000000 + x-ms-version: + - '2019-02-02' + status: + code: 202 + message: Accepted version: 1 diff --git a/sdk/storage/azure-storage-blob/tests/test_container.py b/sdk/storage/azure-storage-blob/tests/test_container.py index d558eff2164e..b22e6e1ce07b 100644 --- a/sdk/storage/azure-storage-blob/tests/test_container.py +++ b/sdk/storage/azure-storage-blob/tests/test_container.py @@ -27,6 +27,7 @@ StandardBlobTier, PremiumPageBlobTier, generate_container_sas, + PartialBatchErrorException ) from azure.identity import ClientSecretCredential @@ -1001,6 +1002,7 @@ def test_delete_blobs_simple(self): 'blob2', 'blob3', ) + response = list(response) assert len(response) == 3 assert response[0].status_code == 202 assert response[1].status_code == 202 @@ -1008,36 +1010,65 @@ def test_delete_blobs_simple(self): @pytest.mark.skipif(sys.version_info < (3, 0), reason="Batch not supported on Python 2.7") @record - def test_delete_blobs_snapshot(self): + def test_delete_blobs_simple_no_raise(self): # Arrange container = self._create_container() data = b'hello world' try: - blob1_client = container.get_blob_client('blob1') - blob1_client.upload_blob(data) - blob1_client.create_snapshot() + container.get_blob_client('blob1').upload_blob(data) container.get_blob_client('blob2').upload_blob(data) container.get_blob_client('blob3').upload_blob(data) except: pass - blobs = list(container.list_blobs(include='snapshots')) - assert len(blobs) == 4 # 3 blobs + 1 snapshot # Act response = container.delete_blobs( 'blob1', 'blob2', 'blob3', - delete_snapshots='only' + raise_on_any_failure=False ) assert len(response) == 3 assert response[0].status_code == 202 - assert response[1].status_code == 404 # There was no snapshot - assert response[2].status_code == 404 # There was no snapshot + assert response[1].status_code == 202 + assert response[2].status_code == 202 + + @pytest.mark.skipif(sys.version_info < (3, 0), reason="Batch not supported on Python 2.7") + @record + def test_delete_blobs_snapshot(self): + # Arrange + container = self._create_container() + data = b'hello world' + try: + blob1_client = container.get_blob_client('blob1') + blob1_client.upload_blob(data) + blob1_client.create_snapshot() + container.get_blob_client('blob2').upload_blob(data) + container.get_blob_client('blob3').upload_blob(data) + except: + pass blobs = list(container.list_blobs(include='snapshots')) - assert len(blobs) == 3 # 3 blobs + assert len(blobs) == 4 # 3 blobs + 1 snapshot + + # Act + try: + response = container.delete_blobs( + 'blob1', + 'blob2', + 'blob3', + delete_snapshots='only' + ) + except PartialBatchErrorException as err: + parts = list(err.parts) + assert len(parts) == 3 + assert parts[0].status_code == 202 + assert parts[1].status_code == 404 # There was no snapshot + assert parts[2].status_code == 404 # There was no snapshot + + blobs = list(container.list_blobs(include='snapshots')) + assert len(blobs) == 3 # 3 blobs @pytest.mark.skipif(sys.version_info < (3, 0), reason="Batch not supported on Python 2.7") @record @@ -1045,13 +1076,13 @@ def test_standard_blob_tier_set_tier_api_batch(self): container = self._create_container() tiers = [StandardBlobTier.Archive, StandardBlobTier.Cool, StandardBlobTier.Hot] - response = container.delete_blobs( - 'blob1', - 'blob2', - 'blob3', - ) - for tier in tiers: + response = container.delete_blobs( + 'blob1', + 'blob2', + 'blob3', + raise_on_any_failure=False + ) blob = container.get_blob_client('blob1') data = b'hello world' blob.upload_blob(data) @@ -1082,11 +1113,12 @@ def test_standard_blob_tier_set_tier_api_batch(self): assert not blob_ref2.blob_tier_inferred assert blob_ref2.blob_tier_change_time is not None - response = container.delete_blobs( - 'blob1', - 'blob2', - 'blob3', - ) + response = container.delete_blobs( + 'blob1', + 'blob2', + 'blob3', + raise_on_any_failure=False + ) @pytest.mark.skip(reason="Wasn't able to get premium account with batch enabled") # once we have premium tests, still we don't want to test Py 2.7 diff --git a/sdk/storage/azure-storage-blob/tests/test_container_async.py b/sdk/storage/azure-storage-blob/tests/test_container_async.py index 8337b796e1b5..3d0b2c07aaf7 100644 --- a/sdk/storage/azure-storage-blob/tests/test_container_async.py +++ b/sdk/storage/azure-storage-blob/tests/test_container_async.py @@ -28,7 +28,8 @@ ContainerSasPermissions, StandardBlobTier, PremiumPageBlobTier, - generate_container_sas + generate_container_sas, + PartialBatchErrorException ) from azure.storage.blob.aio import ( @@ -1250,40 +1251,74 @@ async def _test_delete_blobs_simple(self): assert response[2].status_code == 202 @record - def test_delete_blobs_snapshot(self): + def test_delete_blobs_simple_no_raise_async(self): + if TestMode.need_recording_file(self.test_mode): + return loop = asyncio.get_event_loop() - loop.run_until_complete(self._test_delete_blobs_snapshot()) + loop.run_until_complete(self._test_delete_blobs_simple()) - async def _test_delete_blobs_snapshot(self): + async def _test_delete_blobs_simple_no_raise(self): # Arrange container = await self._create_container() data = b'hello world' try: - blob1_client = container.get_blob_client('blob1') - await blob1_client.upload_blob(data) - await blob1_client.create_snapshot() + await container.get_blob_client('blob1').upload_blob(data) await container.get_blob_client('blob2').upload_blob(data) await container.get_blob_client('blob3').upload_blob(data) except: pass - blobs = await _to_list(container.list_blobs(include='snapshots')) - assert len(blobs) == 4 # 3 blobs + 1 snapshot # Act response = await _to_list(await container.delete_blobs( 'blob1', 'blob2', 'blob3', - delete_snapshots='only' + raise_on_any_failure=False )) assert len(response) == 3 assert response[0].status_code == 202 - assert response[1].status_code == 404 # There was no snapshot - assert response[2].status_code == 404 # There was no snapshot + assert response[1].status_code == 202 + assert response[2].status_code == 202 + + @record + def test_delete_blobs_snapshot(self): + loop = asyncio.get_event_loop() + loop.run_until_complete(self._test_delete_blobs_snapshot()) + + async def _test_delete_blobs_snapshot(self): + # Arrange + container = await self._create_container() + data = b'hello world' + try: + blob1_client = container.get_blob_client('blob1') + await blob1_client.upload_blob(data) + await blob1_client.create_snapshot() + await container.get_blob_client('blob2').upload_blob(data) + await container.get_blob_client('blob3').upload_blob(data) + except: + pass blobs = await _to_list(container.list_blobs(include='snapshots')) - assert len(blobs) == 3 # 3 blobs + assert len(blobs) == 4 # 3 blobs + 1 snapshot + + # Act + try: + response = await _to_list(await container.delete_blobs( + 'blob1', + 'blob2', + 'blob3', + delete_snapshots='only' + )) + except PartialBatchErrorException as err: + parts_list = err.parts + assert len(parts_list) == 3 + assert parts_list[0].status_code == 202 + assert parts_list[1].status_code == 404 # There was no snapshot + assert parts_list[2].status_code == 404 # There was no snapshot + + blobs = await _to_list(container.list_blobs(include='snapshots')) + assert len(blobs) == 3 # 3 blobs @record def test_standard_blob_tier_set_tier_api_batch(self):