208 Commits

Author SHA1 Message Date
Sean McArthur
be461b4663 perf(http): introduce MemBuf, a shared read buffer 2017-01-16 10:50:35 -08:00
Sean McArthur
2d2d5574a6 feat(lib): redesign API to use Futures and Tokio
There are many changes involved with this, but let's just talk about
user-facing changes.

- Creating a `Client` and `Server` now needs a Tokio `Core` event loop
to attach to.
- `Request` and `Response` both no longer implement the
`std::io::{Read,Write}` traits, but instead represent their bodies as a
`futures::Stream` of items, where each item is a `Chunk`.
- The `Client.request` method now takes a `Request`, instead of being
used as a builder, and returns a `Future` that resolves to `Response`.
- The `Handler` trait for servers is no more, and instead the Tokio
`Service` trait is used. This allows interoperability with generic
middleware.

BREAKING CHANGE: A big sweeping set of breaking changes.
2017-01-16 10:44:27 -08:00
Ed Barnard
d67dbc6028 feat(server): Server::new can take one or more listeners
Closes #859
2016-07-18 15:32:38 -07:00
Sean McArthur
2904668105 feat(client): implement connection pooling for Client
Closes #830
Closes #848
2016-07-08 10:07:02 -07:00
Sean McArthur
2fbd80ce69 feat(server): add Transport to on_request 2016-06-23 15:29:30 -07:00
Sean McArthur
c856de0428 feat(client): add method to end a chunked body for a Request
Closes #831
2016-06-17 07:01:42 -07:00
Sean McArthur
2d9aea8db0 fix(client): send query parameters in Requests 2016-05-23 11:19:43 -07:00
Sean McArthur
d35992d019 feat(lib): switch to non-blocking (asynchronous) IO
BREAKING CHANGE: This breaks a lot of the Client and Server APIs.
  Check the documentation for how Handlers can be used for asynchronous
  events.
2016-05-16 09:51:18 -07:00