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

add retry to gcs.upload_file #3232

Merged
merged 6 commits into from
May 7, 2024
Merged

add retry to gcs.upload_file #3232

merged 6 commits into from
May 7, 2024

Conversation

bigning
Copy link
Contributor

@bigning bigning commented Apr 30, 2024

What?

One of our client has the GCS upload error. The default DEFAULT_RETRY_IF_GENERATION_SPECIFIED only works if generation is specified which is not the case in our code. So we change to DEFAULT_RETRY to enable the retry

Related issues: googleapis/python-storage#1231
configure retries: https://cloud.google.com/python/docs/reference/storage/latest/retry_timeout
what's generation number: https://medium.com/codebrace/using-object-versioning-for-google-cloud-storage-5577769d2c83

Copy link
Contributor

@mvpatel2000 mvpatel2000 left a comment

Choose a reason for hiding this comment

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

Is this ready for review? not sure because marked as draft

@bigning
Copy link
Contributor Author

bigning commented Apr 30, 2024

Is this ready for review? not sure because marked as draft

@mvpatel2000 , waiting for customer's test and feedback

@bigning
Copy link
Contributor Author

bigning commented May 6, 2024

Get feedback from customer, this fixed the checkpoint uploading issue. cc @mvpatel2000

@bigning bigning marked this pull request as ready for review May 6, 2024 17:51
@bigning bigning requested review from mvpatel2000 and eracah May 6, 2024 17:51
@bigning bigning enabled auto-merge (squash) May 7, 2024 21:06
@bigning bigning merged commit 9538777 into dev May 7, 2024
15 checks passed
@bigning bigning deleted the gcs_upload_retry branch May 7, 2024 21:33
j316chuck pushed a commit that referenced this pull request May 16, 2024
* add retry to gcs.upload_file

* fix unit test
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants