Skip to content

Explore the idea to provide non-async APIs #176

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

Open
m4tx opened this issue Feb 18, 2025 · 0 comments
Open

Explore the idea to provide non-async APIs #176

m4tx opened this issue Feb 18, 2025 · 0 comments
Labels
help wanted Extra attention is needed

Comments

@m4tx
Copy link
Member

m4tx commented Feb 18, 2025

While async bring some nice features and makes it easy to create code that "does a few things at once", it's generally more difficult to write, reason about, and debug.

It might be useful to consider providing a non-async APIs that would be used by default, and make async an option that you need to consciously decide to use.

A more lightweight alternative would be to remove the Send + 'static bound on the request handlers. This can be done with pure hyper (no axum): https://emschwartz.me/async-rust-can-be-a-pleasure-to-work-with-without-send-sync-static/

@m4tx m4tx added the help wanted Extra attention is needed label Feb 18, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
help wanted Extra attention is needed
Projects
None yet
Development

No branches or pull requests

1 participant