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

Use externally provided ressources (tokio runtime / rayon thread pool) #19650

Open
AntoinePrv opened this issue Nov 5, 2024 · 0 comments
Open
Labels
enhancement New feature or an improvement of an existing feature

Comments

@AntoinePrv
Copy link

Description

In application where Polars share resources with other demanding functionalities, such as a tokio webserver, having two runtimes (one for web, one for Polars) feels like it would result to sub-optimal use of each runtime (if they are both constrained) or over-subscription (if they each have access to all os threads).
Would it make sense to allow setting Polars tokio runtime from user code?

Same reasoning applies to the rayon thread pool. It is my understanding that letting user provide the resources to algorithms in a library increase composability while reducing the burden on library developer to manage globals.

@AntoinePrv AntoinePrv added the enhancement New feature or an improvement of an existing feature label Nov 5, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or an improvement of an existing feature
Projects
None yet
Development

No branches or pull requests

1 participant