Sean McArthur
6b47c69f4a
test(http1): add benchmarks for fixed and chunked decoding
2020-02-19 13:43:26 -08:00
Sean McArthur
14fc2d00f1
style(http2): format http2 code
2020-02-19 12:29:59 -08:00
Sean McArthur
cc6b396e65
refactor(h2): change error message when poll capacity is canceled
2020-02-19 11:07:05 -08:00
daxpedda
24d53d3f66
feat(server): add poll_peek to AddrStream ( #2127 )
2020-02-17 11:31:36 -08:00
Sean McArthur
dd02254ae8
style(lib): apply latest rustfmt
2020-02-06 11:41:25 -08:00
Sean McArthur
141207769f
v0.13.2
2020-01-29 12:41:58 -08:00
Sean McArthur
6cf6245741
refactor(client): touch up connect log formats
2020-01-29 12:29:46 -08:00
Sean McArthur
2983395d63
chore(lib): update pretty_env_logger to v0.4 ( #2123 )
2020-01-29 12:08:43 -08:00
Sean McArthur
dc88204716
fix(body): return exactly 0 SizeHint for empty body ( #2122 )
2020-01-29 11:55:07 -08:00
Sean McArthur
9d1271384b
docs(examples): rename proxy example to gateway
2020-01-29 11:10:48 -08:00
Sean McArthur
5c6536317c
docs(examples): improve README for examples directory
2020-01-29 11:09:21 -08:00
Kelly Thomas Kline
086fa359ff
docs(readme): Add link to warp ( #2081 )
2020-01-29 10:26:59 -08:00
Linus Färnstrand
de7418da2f
style(lib): use just std instead of ::std in paths ( #2101 )
2020-01-29 10:25:57 -08:00
Sean McArthur
c4bb4db5c2
fix(http1): only send 100 Continue if request body is polled
...
Before, if a client request included an `Expect: 100-continue` header,
the `100 Continue` response was sent immediately. However, this is
problematic if the service is going to reply with some 4xx status code
and reject the body.
This change delays the automatic sending of the `100 Continue` status
until the service has call `poll_data` on the request body once.
2020-01-28 17:32:58 -08:00
Sean McArthur
a354580e3f
perf(body): reduce memory size of Body by a u64 ( #2118 )
...
Replaces the `Option<u64>` content-length with a `DecodedLength`, which
stores its unknown-ness as `u64::MAX`.
2020-01-27 13:09:40 -08:00
Sean McArthur
1881db6391
fix(http1): remove panic for HTTP upgrades that have been ignored ( #2115 )
...
Closes #2114
2020-01-23 16:41:40 -08:00
Sean McArthur
ba2a144f8b
fix(client): strip path from Uri before calling Connector ( #2109 )
2020-01-13 11:45:28 -08:00
Markus Westerlind
a5720fab4c
feat(service): Implement Clone/Copy on ServiceFn and MakeServiceFn ( #2104 )
2020-01-08 12:44:07 -08:00
danieleades
0eaf304644
style(lib): address most clippy lints
2020-01-03 09:40:32 -08:00
danieleades
0f13719873
refactor(error): remove deprecated 'Error::description' method ( #2092 )
2019-12-30 09:55:08 -08:00
guoyunlong16
fb90d30c02
fix(http2): don't add client content-length if method doesn't require it
2019-12-26 10:41:52 -08:00
Vivek Ghaisas
35825c4614
style(comments): correct some typos in Rust code comments
2019-12-20 10:16:36 -08:00
Sean McArthur
6d2bcef272
perf(upgrade): forward vectored writes on the Upgraded type
2019-12-19 15:33:12 -08:00
Sean McArthur
61b62eeac8
v0.13.1
2019-12-16 11:44:04 -08:00
Sean McArthur
4b6099c7aa
feat(body): implement HttpBody for Request and Response
...
When the body type of a `Request` or `Response` implements `HttpBody`,
the `Request` or `Response` itself now implements `HttpBody`.
This allows writing things like `hyper::body::aggregate(req)` instead of
`hyper::body::aggregate(req.into_body())`.
Closes #2067
2019-12-13 10:48:30 -08:00
Euclidr
bfda390617
docs(server): http_proxy example
2019-12-12 16:59:38 -08:00
Sean McArthur
703ac340cb
docs(body): fill in documentation of the to_bytes function
2019-12-12 15:26:54 -08:00
Sean McArthur
cb71d2cdbd
fix(http1): fix response with non-chunked transfer-encoding to be close-delimited
...
Closes #2058
2019-12-12 14:26:56 -08:00
Sean McArthur
e12329054a
refactor(http1): fix for unused must_use on read_buf.split_to
2019-12-12 14:17:33 -08:00
Sean McArthur
d1f6136ce2
test(http1): only enable WriteBuf non-empty test with debug-assertions
...
Closes #2062
2019-12-12 12:12:32 -08:00
Sean McArthur
2553ea1a7a
feat(client): expose hyper::client::connect::Connect trait alias
...
This is *just* a "trait alias". It is automatically implemented for all
`Service<Uri>`s that have the required bounds. It's purpose being public
is to ease setting trait bounds outside of hyper. Therefore, it doesn't
have any exposed associated types, to prevent otherwise relying on any
super-traits that hyper requires.
2019-12-12 11:58:05 -08:00
Sean McArthur
a07142da2d
refactor(client): remove Unpin requirement from request body
2019-12-11 14:18:56 -08:00
Sean McArthur
52cc3f7367
refactor(client): remove Unpin requirement on Body::Data
2019-12-11 14:18:56 -08:00
Sean McArthur
57ef271500
docs(lib): fix broken intra docs links
2019-12-11 13:23:36 -08:00
Sean McArthur
bdca4992fc
chore(CI): add cargo doc step to CI
2019-12-11 13:23:36 -08:00
Sean McArthur
e0ea2aeeca
docs(server): fix ICE documenting pub(super) through pin_project
2019-12-11 13:23:36 -08:00
Sean McArthur
070c84ec43
v0.13.0
2019-12-10 09:45:42 -08:00
Frank Denis
164feec941
docs(client): a custom connector must be implement the Clone trait ( #2064 )
2019-12-10 09:35:39 -08:00
Sean McArthur
f45137ad6d
refactor(server): remove deprecated API
2019-12-09 13:17:47 -08:00
David Barsky
c775525109
docs(lib): fix typo in README.md
2019-12-09 13:04:15 -08:00
Sean McArthur
5b48ec0fe5
docs(lib): rewrite hyper overview
2019-12-09 11:50:53 -08:00
Sean McArthur
78e8da17cf
docs(body): small wording improvement to body module docs
2019-12-06 15:50:02 -08:00
Sean McArthur
86fbbad49e
docs(server): tweaks to server doc example
2019-12-06 15:50:02 -08:00
Sean McArthur
7e91029e0e
docs(client): update client example to use to_bytes
2019-12-06 15:50:02 -08:00
Sean McArthur
245fa9c44c
refactor(server): remove Unpin requirement from the Body generic
2019-12-06 13:27:08 -08:00
Sean McArthur
71101e701f
docs(client): show how to implement a Connector
2019-12-06 11:58:01 -08:00
Sean McArthur
8ba9a8d2c4
feat(body): add body::aggregate and body::to_bytes functions
...
Adds utility functions to `hyper::body` to help asynchronously
collecting all the buffers of some `HttpBody` into one.
- `aggregate` will collect all into an `impl Buf` without copying the
contents. This is ideal if you don't need a contiguous buffer.
- `to_bytes` will copy all the data into a single contiguous `Bytes`
buffer.
2019-12-06 10:03:05 -08:00
Sean McArthur
5a59875742
feat(body): replace Chunk type with Bytes
...
Closes #1931
BREAKING CHANGE: All usage of `hyper::Chunk` should be replaced with
`bytes::Bytes` (or `hyper::body::Bytes`).
2019-12-05 17:22:13 -08:00
Sean McArthur
c56ccfb033
chore(ci): remove .appveyor.yml file
2019-12-05 14:08:40 -08:00
Sean McArthur
a1e87c7fe6
chore(README): update CI badge
2019-12-05 14:08:02 -08:00