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

[Feature request] Layer to support delegating requests to arbitrary executor #807

Open
jlizen opened this issue Dec 23, 2024 · 1 comment

Comments

@jlizen
Copy link
Contributor

jlizen commented Dec 23, 2024

(Glad to contribute this, cutting an issue to gauge interest first)

Today we have the buffer layer which allows delegating requests to a background worker, but in serial.

I recently cut a change to reqwest that includes example code for a similar sort of layer, but this time processed in parallel by a different executor. It was fairly verbose boilerplate.

Would we want something similar in the tower's built in layers, under a feature flag? I could make it somewhat less opinionated by accepting an executor trait implementation. Or is that too niche to include in the main package?

Open to contributing something along these lines, but seeking feedback about what's useful (if anything :) )

@jlizen
Copy link
Contributor Author

jlizen commented Dec 23, 2024

cc @seanmonstar as you have context on the above code

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

No branches or pull requests

1 participant