Use the newer recommended S3 ListObjectsV2 API#1
Open
giuli007 wants to merge 1 commit intoissue/989-add-zstandard-supportfrom
Open
Use the newer recommended S3 ListObjectsV2 API#1giuli007 wants to merge 1 commit intoissue/989-add-zstandard-supportfrom
giuli007 wants to merge 1 commit intoissue/989-add-zstandard-supportfrom
Conversation
This was referenced Mar 22, 2022
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Fixes
This change is to addresses a situation we have encountered running in AWS EKS where each single (1000-paginated) request using the older
ListObjectsAPI vias3.ListObjectsPagestakes seconds to receive a response, resulting in tens of minutes long publishing times when the bucket contains >100k packages (which is the cases for repos mirrored from ubuntu repos and republished in-house).This doesn't look like normal throttling as no explicit throttled responses are seen when enabling
debugin the https://www.aptly.info/doc/configuration/. The reasons why the old API is so slow only when running in EKS are still unknown.Description of the Change
Uses the more modern recommended
ListObjectsV2to list objects on the S3 bucket when publishing to it.https://docs.aws.amazon.com/AmazonS3/latest/API/API_ListObjectsV2.html
This is faster, especially when running in EKS.
These changes are based off the
issue/989-add-zstandard-supportbranch (same as aptly-dev#1002) which includes changes made by ahaswell that we are already using internally.These changes live on my personal repo temporarily. I plan on including them (as well as those on
issue/989-add-zstandard-support) into a repo owned by the Yelp org and to eventually build it from there (and potentially also make a PR upstream from there).Checklist
AUTHORS