poem
poem copied to clipboard
Add support for converting Server into Tower Service
Description of the feature
Many other Rust servers can be converted into Tower Services. For example:
- Tonic: https://docs.rs/tonic/latest/tonic/transport/server/struct.Router.html#method.into_service
- Axum: https://docs.rs/axum/latest/axum/handler/trait.HandlerWithoutStateExt.html#tymethod.into_service
This is great for interoperability. For example, it'd make it very easy to use Poem alongside other servers behind a proxy, a la the request in https://github.com/poem-web/poem/issues/478.