Jeb Rosen
3f4f155e1c
Use 'body_string_wait' in all example tests.
2019-09-21 11:37:20 -07:00
Redrield
a277d91c48
Upgrade 'msgpack' for async in contrib and examples.
2019-09-21 11:37:20 -07:00
Jeb Rosen
2109235e01
Update parts of contrib and associated tests and examples:
...
* json
* templates
* helmet
* databases
* serve
* examples/cookies
* examples/handlebars_templates
* examples/json
* examples/session
* examples/static_files
* examples/tera_templates
2019-09-21 11:37:20 -07:00
Jeb Rosen
2f3edd7793
Make 'Fairing::on_response' and 'Responder::respond_to' async.
...
This is required to be able to do anything useful with the body in the
outgoing response. Request fairings do not appear to need to be async
as everything on Data that returns a future moves self and on_request only
gets &Data, but the same change in this commit should work for on_request
if desired.
2019-09-21 11:37:20 -07:00
Jeb Rosen
6b8a7fa3f2
Update core lib tests for async.
...
Adds body_string_wait and body_bytes_wait functions to LocalRequest for convenience.
2019-09-21 11:37:20 -07:00
Jeb Rosen
f83caf2d08
Stream body data instead of buffering it.
...
This requires some awkward channel and spawning work because
Body might contain borrowed data.
2019-09-21 11:37:20 -07:00
Jeb Rosen
0fe3f39304
Use AddrIncoming/AddrStream.
...
This lets us keep support for keep-alive and remote address while doing
other work on async, at the cost of TLS. Abstracting over the connection
type will be done more thoroughly later.
2019-09-21 11:37:20 -07:00
Jeb Rosen
e8322dbfb4
Add async_await feature to examples to make them more check-able.
2019-09-21 11:37:20 -07:00
Jeb Rosen
e0ca328f48
Convert core to async and add support for async routes.
...
Minimum rustc bump required for rust-lang/rust#61775
2019-09-21 11:37:20 -07:00
Jeb Rosen
7bf59f467c
Clean up, preparing to merge in other changes.
2019-09-21 10:21:36 -07:00
Marc Schreiber
c067fd396f
Upgrade to hyper 0.12:
...
- Use hyper's MakeService implementation with futures API
- Use tokio runtime to serve HTTP backend
2019-09-21 10:21:34 -07:00
Jacob Pratt
4e6a7ddd5f
Remove use of the 'crate_visibility_modifier' feature.
...
Most items with 'crate' visibility become 'pub(crate)'.
Items are made 'pub' instead when they would remain private.
2019-09-21 09:16:04 -07:00
Jeb Rosen
335d8f7dbb
Adjust '#[catch]' codegen output to fix a UI test regression in latest nightly.
2019-09-21 08:33:16 -07:00
Sergio Benitez
777d01fa87
Remove unused features in contrib codegen.
2019-09-18 19:34:03 -07:00
Jacob Pratt
bed93133b8
Abide by formatting in 'Debug' implementations.
2019-09-18 19:06:08 -07:00
Jacob Pratt
e3c1a4ad3a
Remove use of the 'try_trait' feature.
...
Add the 'try_outcome' macro to replace uses of '?' on 'Outcome'.
2019-09-18 18:43:16 -07:00
Jacob Pratt
b95b6765e1
Remove use of 'label_break_value' feature.
2019-09-10 17:27:40 -07:00
Sergio Benitez
2537a1164d
Remove 'Result' specialization. Add 'Debug' responder.
...
This removes all uses of specialization in Rocket.
2019-09-09 21:57:33 -07:00
Sergio Benitez
592e441de5
Use proper span in responder codegen output.
2019-09-09 21:57:10 -07:00
Sergio Benitez
3fae9919f7
Deprecate 'Result<T, E>, E: !Responder' responder.
2019-09-09 21:56:55 -07:00
Sergio Benitez
22da02fa64
Remove double semicolons; silence test warnings.
2019-09-09 16:57:03 -07:00
Sergio Benitez
b7e688cefa
Remove use of deprecated 'IndexMap::remove()'.
...
Use 'IndexMap::swap_remove()' in its place.
2019-09-09 16:51:51 -07:00
Sergio Benitez
99a864008c
Remove use of specialization in http.
2019-09-09 16:45:03 -07:00
Sergio Benitez
6ed4c098f1
Stop exporting 'mime' and relevant conversions.
2019-09-09 16:42:44 -07:00
Sergio Benitez
c5973f01df
Remove use of specialization in 'status::Created'.
2019-09-09 16:37:46 -07:00
Christian Bourjau
ed6661abaa
Fix typo in README: missing 'a'.
2019-09-07 09:53:37 -07:00
Sergio Benitez
0b059e06e5
Update 'devise' to 0.3.
...
This transitively updates 'syn', 'proc-macro2', and 'quote' to 1.0.
2019-09-05 15:44:25 -07:00
Sergio Benitez
dcea9563fc
Update UI tests for latest nightly.
2019-08-26 12:48:32 -07:00
Pieter Frenssen
1383671090
Do not display 'Error:' on a successful logout in the 'session' example.
2019-08-12 17:39:52 -07:00
Jacob Pratt
2dd09f90be
Remove unused 'doc_cfg' feature.
2019-08-06 14:01:35 -07:00
Sergio Benitez
b8ab9e5b23
Add template engine versions to docs.
2019-07-19 13:35:29 -07:00
Ning Sun
93c979eb43
Update 'handlebars' to 2.0.
2019-07-19 13:34:38 -07:00
Jeb Rosen
3e4f8453ce
Remove use of the 'decl_macro' feature.
...
Also removes one internal use in the 'typed-uris' codegen test.
2019-07-19 11:39:56 -07:00
Jeb Rosen
2f458b5217
Remove dependence on 'decl_macro' in codegen.
...
The generated 'uri' helper macros are now re-exports of 'macro_rules'
macros, made possible by the stable 'uniform_paths' feature.
2019-07-19 11:38:35 -07:00
Jacob Pratt
34a741a26e
Remove use of '!' type in favor of 'Infallible'.
...
This removes the use of and dependence on the 'never_type' feature.
2019-07-09 15:10:51 -07:00
Sergio Benitez
21b10176ee
Forward from 'StaticFiles' if a file is not found.
...
Also adds a 'handler::Outcome::from_or_forward' method for easily
constructing handler outcomes that forward on responder failures.
Fixes #1036 .
2019-07-07 23:22:38 -07:00
Dmitry Murzin
c100a92127
Implement 'FromParam' for 'NonZero*' types.
2019-07-06 13:32:08 -07:00
Sergio Benitez
fbece2d70d
Add nightly build task.
2019-07-06 01:15:24 -07:00
Sergio Benitez
bb09a9e720
Update build badge for Azure Pipelines.
2019-07-06 01:03:08 -07:00
Sergio Benitez
fe4fd3e241
Migrate from Travis to Azure Pipelines for CI.
...
Resolves #801 .
2019-07-06 00:59:03 -07:00
Sergio Benitez
7f2c9f426c
Fix tests for Windows.
2019-07-06 00:59:01 -07:00
Sergio Benitez
b5b4c696f8
Stop caching for a working Travis CI.
2019-06-28 18:33:39 -07:00
Sergio Benitez
e9c125ffa0
Update CHANGELOG for 0.4.2.
2019-06-28 18:31:28 -07:00
Sergio Benitez
1f9020d26f
Fix link to 'Rustqlite' in databases docs.
2019-06-28 17:38:08 -07:00
Jeb Rosen
fc78eaf836
Document contrib database library versions.
...
This commit also adds a note to the contrib database documentation
describing how to enable features in upstream database crates.
2019-06-26 09:11:27 -04:00
Sergio Benitez
da7e022f99
Add Rust 2015 example.
2019-06-25 11:30:43 -07:00
Jeb Rosen
d9f989a496
Migrate all examples to Rust 2018.
2019-06-25 11:30:43 -07:00
Jeb Rosen
2315171971
Migrate contrib to Rust 2018.
2019-06-25 11:30:39 -07:00
Jeb Rosen
be784a7845
Migrate codegen to Rust 2018.
2019-06-25 13:45:27 -04:00
Jeb Rosen
34cb1c14b8
Migrate core to Rust 2018.
2019-06-25 13:45:23 -04:00