Skip to content

Commit d90f0ee

Browse files
authored
feat(experimental): add bidi stream retry manager. (#1632)
- Add bidi stream retry manager. It will the main class that would be responsible for retries. - Integrate MRD with bidi stream retry manager and reads resumption strategy - Added conformance tests for all error scenarios and smart resumption for bidi reads - Refactored MRD's `download_ranges()` method, which will now use retry manager's `execute()` method to send the requests - Modified the logic to parse and handle the `BidiReadObjectRedirectedError`. - Modified cloud build configuration to also pull the latest changes of the current PR. - Formatted few more files using black formatter
1 parent a994dbf commit d90f0ee

16 files changed

+1274
-307
lines changed

cloudbuild/run_zonal_tests.sh

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -6,6 +6,7 @@ sudo apt-get update && sudo apt-get install -y git python3-pip python3-venv
66
# Clone the repository and checkout the specific commit from the build trigger.
77
git clone https://github.com/googleapis/python-storage.git
88
cd python-storage
9+
git fetch origin "refs/pull/${_PR_NUMBER}/head"
910
git checkout ${COMMIT_SHA}
1011

1112

cloudbuild/zb-system-tests-cloudbuild.yaml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -68,7 +68,7 @@ steps:
6868
# Execute the script on the VM via SSH.
6969
# Capture the exit code to ensure cleanup happens before the build fails.
7070
set +e
71-
gcloud compute ssh ${_VM_NAME} --zone=${_ZONE} --internal-ip --ssh-key-file=/workspace/.ssh/google_compute_engine --command="ulimit -n {_ULIMIT}; COMMIT_SHA=${COMMIT_SHA} _ZONAL_BUCKET=${_ZONAL_BUCKET} bash run_zonal_tests.sh"
71+
gcloud compute ssh ${_VM_NAME} --zone=${_ZONE} --internal-ip --ssh-key-file=/workspace/.ssh/google_compute_engine --command="ulimit -n {_ULIMIT}; COMMIT_SHA=${COMMIT_SHA} _ZONAL_BUCKET=${_ZONAL_BUCKET} _PR_NUMBER=${_PR_NUMBER} bash run_zonal_tests.sh"
7272
EXIT_CODE=$?
7373
set -e
7474

google/cloud/storage/_experimental/asyncio/_utils.py

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -16,6 +16,7 @@
1616

1717
from google.api_core import exceptions
1818

19+
1920
def raise_if_no_fast_crc32c():
2021
"""Check if the C-accelerated version of google-crc32c is available.
2122
@@ -24,7 +25,7 @@ def raise_if_no_fast_crc32c():
2425
raises google.api_core.exceptions.FailedPrecondition: If the C extension is not available.
2526
returns: True if the C extension is available.
2627
rtype: bool
27-
28+
2829
"""
2930
if google_crc32c.implementation != "c":
3031
raise exceptions.FailedPrecondition(

0 commit comments

Comments
 (0)