Sean McArthur
6244526a5b
chore(tests): fix not-compiling tests
2018-02-15 12:55:02 -08:00
Sean McArthur
39e03a91e2
perf(server): set TCP keepalive when default listener is used
2018-02-15 12:49:52 -08:00
Sean McArthur
6ef22da8ea
perf(client): set TCP keepalive when default connector is used
2018-02-15 12:40:38 -08:00
Sean McArthur
ee61ea9adf
feat(client): Client will retry requests on fresh connections
...
If a request sees an error on a pooled connection before ever writing
any bytes, it will now retry with a new connection.
This can be configured with `Config::retry_canceled_requests(bool)`.
2018-02-15 12:04:58 -08:00
Sean McArthur
0ea3bcf8d5
refactor(server): add debug log when server accepts new connection
2018-02-12 18:21:20 -08:00
Sean McArthur
dc619a8fa0
fix(client): detect connection closes as pool tries to use
...
Currently, if the remote closes the connection at the same time that the
pool selects it to use for a new request, the connection may actually
hang. This fix will now more allow the keep-alive read to check the
socket even when the `Conn` think it's busy.
If the connection was closed before the request write happened, returns
back an `Error::Cancel`, letting the user know they could safely retry
it.
Closes #1439
2018-02-12 18:16:21 -08:00
Sean McArthur
a9413d7367
fix(uri): make absolute-form uris always have a path
2018-02-08 16:14:02 -08:00
Sean McArthur
8e57338ef0
v0.11.18
2018-02-07 13:59:47 -08:00
Sean McArthur
88f01793be
fix(client): send an Error::Cancel if a queued request is dropped
...
Adds `Error::Cancel` variant.
2018-02-07 13:12:33 -08:00
Sean McArthur
a821a366f1
chore(h1): remove accidental BufDeque::bytes code
2018-02-06 16:14:09 -08:00
Sean McArthur
b0aa649725
feat(client): add http1_writev configuration option
...
Setting this to false will force HTTP/1 connections to always flatten
all buffers (headers and body) before writing to the transport. The
default is true.
2018-02-06 14:53:21 -08:00
Sean McArthur
d2fdf1f525
perf(h1): convert buffer to flatten strategy with auto detection
2018-02-06 14:35:47 -08:00
Sean McArthur
3a124462c6
test(h1): fix flaky streaming test
2018-02-06 13:25:10 -08:00
Sean McArthur
648548cfa3
test(client): add benchmarks for new cancelable queue
2018-02-06 12:31:31 -08:00
Sean McArthur
1eb18a9e44
v0.11.17
2018-02-05 16:37:43 -08:00
Sean McArthur
731096947d
fix(h1): fix hung streaming bodies over HTTPS
2018-02-05 16:33:23 -08:00
Sean McArthur
0c290c32c9
refactor(h1): reduce noisy read_mem logs
2018-02-05 11:53:49 -08:00
Sean McArthur
b7293ca6ff
refactor(client): clean up pool Checkout::poll function
2018-02-05 11:53:17 -08:00
Sean McArthur
265ad67c86
fix(client): more reliably detect closed pooled connections ( #1434 )
2018-02-05 09:56:29 -08:00
Sean McArthur
8fb84d29a1
refactor(server): add private constructor to AddrIncoming and AddrSteram
2018-02-01 12:41:58 -08:00
Sean McArthur
1aa3835660
refactor(server): use AddrIncoming in Server::run
2018-02-01 12:24:35 -08:00
Sean McArthur
b14de9eb34
refactor(client): fix up should_close sentinel value
2018-01-30 17:09:16 -08:00
Sean McArthur
84f3076438
perf(client): don't make a copy of Headers each Request
2018-01-30 14:58:51 -08:00
Sean McArthur
bf5eb5e0a0
v0.11.16
2018-01-30 13:28:13 -08:00
Sean McArthur
2a74b91181
docs(server): deprecated bind_connection, note about Connection's Opaque item
2018-01-30 13:18:51 -08:00
Sean McArthur
44af273853
fix(client): check for dead connections in Pool
...
Closes #1429
2018-01-29 11:58:05 -08:00
Sean McArthur
a3f87c0b3f
chore(header): fix unused_unsafe in internals
2018-01-29 10:40:21 -08:00
kud1ing
1f8b3541e2
docs(README): "1.0 milestone" => "milestones"
...
The 1.0 milestone has currently no issues but the 0.12 milestone has. So instead of adjusting the README.md for each next mileston, just link to all milestones
2018-01-26 12:34:05 -08:00
Sean McArthur
c33b9d4e16
refactor(proto): move more h1-specific pieces into h1 module
2018-01-25 14:40:09 -08:00
Sean McArthur
68377ede70
perf(http): utilize writev when possible
...
By using `AsyncWrite::write_buf`, we can avoid some copies in some
cases. This especially helps throughput for chunked encoding.
2018-01-25 14:02:11 -08:00
Steven Fackler
11b49c2cc8
feat(uri): Add a PartialEq<str> impl for Uri
2018-01-25 12:00:09 -08:00
Sean McArthur
5c170e8ccd
test(server): improve server throughput benchmarks
2018-01-24 11:38:00 -08:00
Sean McArthur
4de0de73be
test(benches): fix deprecated futures usage in benches
2018-01-23 16:34:16 -08:00
Sean McArthur
d22deb6572
feat(server): add Http::max_buf_size() option
...
The internal connection's read and write bufs will be restricted from
growing bigger than the configured `max_buf_size`.
Closes #1368
2018-01-23 16:09:28 -08:00
Sean McArthur
7cb72d2019
fix(server): send 400 responses on parse errors before closing connection
2018-01-23 15:31:26 -08:00
Sean McArthur
44c34ce9ad
fix(server): error if Response code is 1xx
...
Returning a Response from a Service with a 1xx StatusCode is not
currently supported in hyper. It has always resulted in broken
semantics. This patch simply errors better.
- A Response with 1xx status is converted into a 500 response with no body.
- An error is returned from the `server::Connection` to alert about the
bad response.
2018-01-23 13:02:56 -08:00
Sean McArthur
227742221f
fix(client): error on unsupport 101 responses, ignore other 1xx codes
2018-01-23 11:33:24 -08:00
Sean McArthur
d8b1aa848c
perf(conn): use AsyncRead::read_buf to try skipping zeroing of buffer
2018-01-22 17:45:02 -08:00
Sean McArthur
be9d5e8d5c
v0.11.15
2018-01-22 12:17:33 -08:00
Sean McArthur
c93b082c85
refactor(compat): use pub(super) to remove compat_impl modules
2018-01-22 10:42:41 -08:00
Sean McArthur
36e66a5054
fix(lib): properly handle HTTP/1.0 remotes
...
- Downgrades internal semantics to HTTP/1.0 if peer sends a message with
1.0 version.
- If downgraded, chunked writers become EOF writers, with the connection
closing once the writing is complete.
- When downgraded, if keep-alive was wanted, the `Connection: keep-alive`
header is added.
Closes #1304
2018-01-22 10:08:27 -08:00
Sean McArthur
7d493aafce
chore(depenencies): update pretty-env-logger to 0.2
2018-01-19 17:37:34 -08:00
Sean McArthur
c89019eb10
feat(client): add executor method when configuring a Client
...
This allows using a future `Executor` other than a `Handle` to execute
the background (connection) tasks needed for sending requests and
responses.
This also deprecates `Client::handle()`, since the executor may not be
a `Handle`.
2018-01-19 16:58:57 -08:00
Sean McArthur
350ce542be
v0.11.14
2018-01-16 14:20:26 -08:00
Sean McArthur
14e4c741dc
fix(tokio-proto): return end-of-body frame correctly for tokio-proto
...
Closes #1414
2018-01-16 14:11:20 -08:00
Greedwolf DSS
73511ac8be
docs(example): fix send file to only send range of buffer read into
2018-01-16 11:52:56 -08:00
Sean McArthur
586993fb2f
chore(dependencies): update pretty_env_logger to rc.2
2018-01-12 12:02:13 -08:00
Sean McArthur
00d6a38547
v0.11.13
2018-01-12 11:38:18 -08:00
Sean McArthur
7a48d0e8b4
fix(lib): properly handle body streaming errors
2018-01-11 13:58:16 -08:00
Sean McArthur
7888451408
refactor(proto): return Error::Incomplete instead of UnexpectedEof
2018-01-11 11:45:28 -08:00