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

DM-33597: Try to add 429 retry to S3 #10

Merged
merged 3 commits into from Mar 28, 2022
Merged

DM-33597: Try to add 429 retry to S3 #10

merged 3 commits into from Mar 28, 2022

Conversation

timj
Copy link
Member

@timj timj commented Mar 22, 2022

Catch the 429 client error and translate it to something
that backoff can catch.

Checklist

  • ran Jenkins
  • added a release note for user-visible changes to doc/changes

@codecov
Copy link

codecov bot commented Mar 22, 2022

Codecov Report

Merging #10 (efbb21e) into main (4c3dfcb) will decrease coverage by 0.55%.
The diff coverage is 53.84%.

@@            Coverage Diff             @@
##             main      #10      +/-   ##
==========================================
- Coverage   86.48%   85.92%   -0.56%     
==========================================
  Files          22       22              
  Lines        2685     2714      +29     
  Branches      397      404       +7     
==========================================
+ Hits         2322     2332      +10     
- Misses        290      304      +14     
- Partials       73       78       +5     
Impacted Files Coverage Δ
python/lsst/resources/_resourcePath.py 94.41% <ø> (ø)
python/lsst/resources/s3.py 81.53% <53.84%> (-8.23%) ⬇️

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 4c3dfcb...efbb21e. Read the comment docs.

@timj
Copy link
Member Author

timj commented Mar 22, 2022

@ktlim I've reorganized the S3 code a bit to try to make it possible to catch a 429 client error. Does this look reasonable? I haven't been able to trigger a 429 myself so I can't test it and we can't deploy ticket branch containers to the IDF.

Copy link
Contributor

@ktlim ktlim left a comment

Choose a reason for hiding this comment

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

The restructuring seems OK, but your new fallback seems potentially problematic.

python/lsst/resources/s3.py Outdated Show resolved Hide resolved
python/lsst/resources/s3.py Outdated Show resolved Hide resolved
Catch the 429 client error and translate it to something
that backoff can catch.

Some backends also need to catch 404 instead of NoSuchKey.
@timj timj merged commit 3b0cdbf into main Mar 28, 2022
@timj timj deleted the tickets/DM-33597 branch March 28, 2022 18:20
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.

None yet

2 participants