Sean McArthur
44837c1b69
Replace getaddrinfo resolver with trust-dns-resolver
2018-12-18 12:54:22 -08:00
quininer
37039760f8
Add rustls support ( #390 )
2018-12-17 11:57:43 -08:00
David Wilemski
6ef2060510
Added dns_threads setter to sync ClientBuilder ( #381 )
2018-11-05 11:27:32 -08:00
Sean McArthur
97393143a5
put all TLS functionality behind a feature flag
...
The "Cargo feature" `default-tls`, which is enabled by default, is
added, with all TLS support relying on it. This allows using reqwest but
disabling the `native-tls` dependency, by disabling this feature.
Closes #225
2018-10-29 16:37:25 -07:00
Sean McArthur
512b80a3ad
ensure async request is canceled if there is a timeout
2018-10-17 13:38:54 -07:00
Sean McArthur
a82232f0ee
always wait a max of 5 seconds for sync Client's background thread to start
2018-10-17 12:33:59 -07:00
Yannick Heinrich
647f59756e
Add missing pub(crate) statements.
2018-10-05 11:19:52 -07:00
Paul Woolcock
4857a5917d
From<http::Response> for Response ( #360 )
...
This adds an implementation to convert a `Response` type from the `http`
crate to the `async_impl::Response` type. This is the first step to
allow us to convert `http::Response` objects to `request::Response`
objects
This also adds an extension trait for the `http::response::Builder`
type. The `http::Response` object does not provide a way to access the
"final" url that the response is derived from, so we can't easily
provide that in the `From<http::Response>` implementation. For users who
are manually constructing `http::Response` objects for use in tests,
etc, they can import this extension trait, which adds a `.url()` builder
method that will allow them to pass a `Url`, which we then convert to
our newtype'd Url and add to the `http::Response`'s `extensions`. Then,
when converting from `http::Response` to `async_impl::Response` we can
pull that value out of the `extensions` and use it to construct the
`async_impl::Response`
Closes #333
2018-10-04 17:38:26 -07:00
Yannick Heinrich
22fa725f48
Document gzip client's behaviour ( #358 )
...
As suggested in #306 , the behaviour of the `auto gzip decompression` should
be clearly explained inside the documentation.
Closes #306
2018-10-03 10:14:41 -07:00
Sean McArthur
15857a11a4
fix streaming body from wrongly returning 'closed connection' error
2018-09-19 16:38:33 -07:00
Sean McArthur
2698148743
fix improper handling of request body backpressure
...
Closes #348
2018-09-19 14:20:12 -07:00
Sean McArthur
610cdd266c
Fix panicking when passed a file:// URL
...
Closes #347
2018-09-18 12:43:54 -07:00
Sean McArthur
ef529df3f2
remove inline annotations on client builder methods
2018-08-23 10:04:25 -07:00
Sean McArthur
afbeb1a384
change ClientBuilders to by-value builders
2018-08-23 10:04:25 -07:00
Sean McArthur
d060891b62
fix async request builder tests
2018-08-15 15:36:05 -07:00
Scott Schroeder
d8e47babf6
change invalid cert api to match native-tls ( #327 )
2018-08-13 15:08:02 -07:00
Yannick Heinrich
11f8588989
upgrade to native-tls 0.2 + invalid certs ( #325 )
...
- Bumps `native-tls` dependency to 0.2 and adapt code accordingly
- Import code used from `tokio-tls` into `connect_async` and adapt dependencies accordinlgy
- Add an option for using `danger_accept_invalid_certs` inside the `Config` struct
2018-08-08 13:14:36 -07:00
Yash Srivastav
c417d6dab8
Upgrade hyper to 0.12
...
Closes #304
2018-07-05 10:03:31 -07:00
knight42
f4437ea7b1
feat: set default headers
2017-10-22 13:01:35 +08:00
Sean McArthur
779f8080ef
change Builders to only error at the end
...
Closes #189
2017-08-31 18:10:45 -07:00
Sean McArthur
cf133f7919
change default Client timeout to 30 seconds
...
Closes #181
2017-08-30 14:18:21 -07:00
Anthony Nowell
646c8b8efc
Support PKCS12 identity on the ClientBuilder
2017-08-25 15:38:45 -07:00
Sean McArthur
dc44e742a0
fix deprecated UnboundedSender::send() to unbounded_send()
2017-08-24 15:23:14 -07:00
Ashley Mannix
e2fa97254e
support async gzip decoding
2017-08-18 19:43:06 +10:00
James Brown
5071438c08
join on client thread when all clients have been dropped, take two
2017-08-17 09:35:30 -07:00
Sean McArthur
8296c5e28e
fix broken doc test
2017-07-13 14:19:22 -07:00
Sean McArthur
7f9750d072
fix doc test on clientbuilder
2017-07-13 13:24:01 -07:00
Sean McArthur
12ee6fbcde
small improvements to docs
2017-07-13 12:17:38 -07:00
Sean McArthur
6cdaff4b66
add a Proxy type
...
Proxies can currently be configured to intercept HTTP, HTTPS, and all
requests. HTTPS tunneling is supported.
Closes #30
2017-06-22 09:49:00 -07:00
Sean McArthur
665b4fe718
upgrade hyper to v0.11
2017-06-21 09:47:21 -07:00
Sean McArthur
e45f234b4a
fix socket_is_dead on windows
2017-06-07 17:02:15 -07:00
Sean McArthur
00382f8d06
use a stale check in the pool
...
Check that a socket is not EOF to reduce the likelihood of using
a bad pooled connection.
2017-06-06 13:31:28 -07:00
Michal Budzynski
026dca2512
Added missing "Errors" sections to client.rs and lib.rs
2017-06-04 04:48:13 +02:00
Sean McArthur
e176dcebca
convert RequestBuilder to a &mut Self builder
...
Closes #108
2017-06-01 16:23:16 -07:00
Tom Prince
a36ed4a87a
Add a conversion from native_tls::Error.
2017-05-31 19:27:45 -06:00
Sean McArthur
8d784faa98
move all configuration from Client to ClientBuilder
2017-05-31 18:14:47 -07:00
Corentin Henry
0f0bf882d9
add an error section to RequestBuilder.json
2017-05-31 17:50:20 -07:00
Corentin Henry
20f2896ab4
tweak add_json_fail test
2017-05-31 17:41:48 -07:00
Corentin Henry
80a80379d3
update json tests
2017-05-31 16:42:44 -07:00
Corentin Henry
2f1b3b352b
handle json serialization errors
...
fixes https://github.com/seanmonstar/reqwest/issues/112
2017-05-31 16:41:45 -07:00
Sean McArthur
7565179a1c
add Request.method_mut, remove set_*
2017-05-31 16:11:23 -07:00
theduke
e9f464aa7e
Add a Request type and refactor execution.
...
A Request can be obtained with RequestBuilder::build(), and executed
with Client::execute().
The RequestBuilder now also builds a Request and forwards it to the
inner client.
The execution logic was moved from Requestbuilder::send() to
ClientRef::execute_request().
2017-05-31 16:06:07 -07:00
Tom Prince
9d6f487646
Use block-style for try_!.
2017-05-31 15:00:12 -06:00
Tom Prince
a2c24a4009
Some slightly less trivial rustfmt changes.
2017-05-31 14:50:32 -06:00
Tom Prince
4c60e6d35f
Really trivial rustfmt changes.
2017-05-31 14:50:32 -06:00
Tom Prince
427602fb08
Move constraint into where clause.
2017-05-31 14:21:16 -06:00
Sean McArthur
82a6eb4939
update ClientBuilder to match builder pattern
2017-05-31 11:38:02 -07:00
Corentin Henry
4b2eda7d29
add custom certificates & disabling hostname verif
2017-05-31 11:38:02 -07:00
Sean McArthur
001528b029
Merge pull request #100 from theduke/improve-basic-auth
...
Improve type signature of RequestBuilder::basic_auth().
2017-05-26 13:56:55 -07:00
theduke
60295dd0fc
Improve type signature of RequestBuilder::basic_auth().
...
Use Into<String> for both arguments to make the API more convenient.
2017-05-23 23:59:53 +02:00