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

Configurable download limit per host #780

Merged
merged 2 commits into from
Sep 9, 2022
Merged

Configurable download limit per host #780

merged 2 commits into from
Sep 9, 2022

Conversation

dirkmc
Copy link
Contributor

@dirkmc dirkmc commented Sep 8, 2022

Limit the amount of space that can be reserved for downloaded data per-host. This helps mitigate against a single host with a slow connection reserving all the download space, when there may be other hosts with faster connections that have not had a chance to propose a deal yet.

For example

  • the total download space is 100GB
  • the percentage per host is limited to 50%

This means that the total amount of space for downloaded data per host is 50GB. The reserved space is the sum of

  • the amount of data queued for download
  • the amount of data currently transferring
  • the amount of data that is in the download staging area (waiting to be handed off to the sealing subsystem)

TODO:

  • Sanity check config params (eg MaxStagingDealsPercentPerHost must be between 0 - 100)
[Dealmaking]
  MaxStagingDealsBytes = 1000
  MaxStagingDealsPercentPerHost = 50

@dirkmc dirkmc marked this pull request as ready for review September 9, 2022 07:45
@dirkmc dirkmc merged commit c402186 into main Sep 9, 2022
@dirkmc dirkmc deleted the feat/limit-per-host branch September 9, 2022 08:51
@parkan
Copy link
Contributor

parkan commented Sep 9, 2022

THANK YOU!!!

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.

3 participants