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

Generate block_infos on request, and not all upfront #10

Open
gabrieldemian opened this issue Aug 27, 2023 · 0 comments
Open

Generate block_infos on request, and not all upfront #10

gabrieldemian opened this issue Aug 27, 2023 · 0 comments
Labels
performance Increase the performance

Comments

@gabrieldemian
Copy link
Owner

gabrieldemian commented Aug 27, 2023

When a new torrent is added to the Disk, it generates all the BlockInfos upfront, and this consumes some memory.

Those blocks should be generated dynamically when the peers request new blocks to the Disk, this would drastically reduce the amount of memory consumed.

Also, this would eliminate the need of using the crate decurse.

@gabrieldemian gabrieldemian added the performance Increase the performance label Aug 27, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
performance Increase the performance
Projects
None yet
Development

No branches or pull requests

1 participant