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

Mem limiter affecting get throughput in corner cases #425

Open
DmitriyMusatkin opened this issue Apr 12, 2024 · 0 comments
Open

Mem limiter affecting get throughput in corner cases #425

DmitriyMusatkin opened this issue Apr 12, 2024 · 0 comments
Labels
bug Something isn't working p2 This is a standard priority issue

Comments

@DmitriyMusatkin
Copy link
Contributor

DmitriyMusatkin commented Apr 12, 2024

Describe the bug

Mem limiter provides a push back mechanism on scheduler if memory usage is getting close to the limit.

With gets there is a chicken and egg problem, since we dont know the size object before doing a get and we want to avoid making additional request to figure out that size before doing a get (cause additional roundtrips for get tank perf). So crt will optimistically do a ranged get with a part size to get a first ranged part and figure out the overall size.

This approach works fine in most cases. But it will unnecessarily slow down gets when part size is huge and gets itself are small. Ex. part size is 1 GB and the files being retrieved are 1mb. Mem limiter in that case would only be able to schedule 4 gets in parallel (assuming 4 gb mem limit), since it would account for the worst case of getting back 1GB part. But in practice we should be able to schedule a lot more gets in parallel, cause they are all small.

refer to aws/aws-sdk-cpp#2922 for example of this in the wild

Expected Behavior

something better?

Current Behavior

download slows down to a crawl on lots of small gets if part size is huge

Reproduction Steps

set part size to a gig and observe downloads on 10k 256kb files

Possible Solution

No response

Additional Information/Context

No response

aws-c-s3 version used

latest

Compiler and version used

every compiler

Operating System and version

every os

@DmitriyMusatkin DmitriyMusatkin added bug Something isn't working needs-triage This issue or PR still needs to be triaged. labels Apr 12, 2024
@jmklix jmklix added p2 This is a standard priority issue and removed needs-triage This issue or PR still needs to be triaged. labels Apr 16, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working p2 This is a standard priority issue
Projects
None yet
Development

No branches or pull requests

2 participants