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

Enable specifying infinite limits with a more "intuitive" magic number like -1 #1935

Closed
BigLep opened this issue Dec 6, 2022 · 1 comment · Fixed by #2000
Closed

Enable specifying infinite limits with a more "intuitive" magic number like -1 #1935

BigLep opened this issue Dec 6, 2022 · 1 comment · Fixed by #2000

Comments

@BigLep
Copy link
Contributor

BigLep commented Dec 6, 2022

I know programmatically one can use inifiteLimits. In the Kubo case where users are defining their limits via config/JSON, it would be useful to have another value that denotes infinity like "-1". Certainly Kubo can create its own infinity value but we'd need to do the conversion when setting up the resource manager and reading limits back out from it. I assume this will be pretty common for other applications building on top of go-libp2p which is what I'm proposing putting it into go-libp2p itself.

Context: this came as part of handling user reports after enabling the resource manager by default in Kubo: ipfs/kubo#9442

@marten-seemann
Copy link
Contributor

This should be covered by #2000. The magic number is not -1, but "unlimited" (in the JSON serialization).

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 a pull request may close this issue.

3 participants