tower-http

Crates.iotower-http
lib.rstower-http
version
sourcesrc
created_at2017-03-10 04:36:50.296787
updated_at2024-11-18 19:30:58.685083
descriptionTower middleware and utilities for HTTP clients and servers
homepagehttps://github.com/tower-rs/tower-http
repositoryhttps://github.com/tower-rs/tower-http
max_upload_size
id8912
Cargo.toml error:TOML parse error at line 19, column 1 | 19 | autolib = false | ^^^^^^^ unknown field `autolib`, expected one of `name`, `version`, `edition`, `authors`, `description`, `readme`, `license`, `repository`, `homepage`, `documentation`, `build`, `resolver`, `links`, `default-run`, `default_dash_run`, `rust-version`, `rust_dash_version`, `rust_version`, `license-file`, `license_dash_file`, `license_file`, `licenseFile`, `license_capital_file`, `forced-target`, `forced_dash_target`, `autobins`, `autotests`, `autoexamples`, `autobenches`, `publish`, `metadata`, `keywords`, `categories`, `exclude`, `include`
size0
Publish (github:tower-rs:publish)

documentation

README

Tower HTTP

Tower middleware and utilities for HTTP clients and servers.

Build status Crates.io Documentation Crates.io

More information about this crate can be found in the crate documentation.

Middleware

Tower HTTP contains lots of middleware that are generally useful when building HTTP servers and clients. Some of the highlights are:

  • Trace adds high level logging of requests and responses. Supports both regular HTTP requests as well as gRPC.
  • Compression and Decompression to compress/decompress response bodies.
  • FollowRedirect to automatically follow redirection responses.

See the docs for the complete list of middleware.

Middleware uses the http crate as the HTTP interface so they're compatible with any library or framework that also uses http. For example hyper.

The middleware were originally extracted from one of @EmbarkStudios internal projects.

Examples

The examples folder contains various examples of how to use Tower HTTP:

Minimum supported Rust version

tower-http's MSRV is 1.66.

Getting Help

If you're new to tower its guides might help. In the tower-http repo we also have a number of examples showing how to put everything together. You're also welcome to ask in the #tower Discord channel or open an issue with your question.

Contributing

:balloon: Thanks for your help improving the project! We are so happy to have you! We have a contributing guide to help you get involved in the Tower HTTP project.

License

This project is licensed under the MIT license.

Contribution

Unless you explicitly state otherwise, any contribution intentionally submitted for inclusion in Tower HTTP by you, shall be licensed as MIT, without any additional terms or conditions.

Commit count: 230

cargo fmt