feat(http1): Add higher-level HTTP upgrade support to Client and Server (#1563)
- Adds `Body::on_upgrade()` that returns an `OnUpgrade` future.
- Adds `hyper::upgrade` module containing types for dealing with
  upgrades.
- Adds `server::conn::Connection::with_upgrades()` method to enable
  these upgrades when using lower-level API (because of a missing
  `Send` bound on the transport generic).
- Client connections are automatically enabled.
- Optimizes request parsing, to make up for extra work to look for
  upgrade requests.
  - Returns a smaller `DecodedLength` type instead of the fatter
    `Decoder`, which should also allow a couple fewer branches.
  - Removes the `Decode::Ignore` wrapper enum, and instead ignoring
    1xx responses is handled directly in the response parsing code.
Ref #1563 
Closes #1395
			
			
This commit is contained in:
		| @@ -50,7 +50,6 @@ | ||||
|  | ||||
| pub mod conn; | ||||
| #[cfg(feature = "runtime")] mod tcp; | ||||
| mod rewind; | ||||
|  | ||||
| use std::fmt; | ||||
| #[cfg(feature = "runtime")] use std::net::SocketAddr; | ||||
|   | ||||
		Reference in New Issue
	
	Block a user