Sergio Benitez
f2d054c4a2
Use upstream hyper.
2017-04-19 23:42:12 -07:00
Sergio Benitez
41386cfb78
Display the port that was resolved, not configured.
2017-04-19 02:51:44 -07:00
Sergio Benitez
0d18faf91e
Add a docstring to the emitted static route info.
...
Resolves #258 .
2017-04-18 22:05:56 -07:00
Sergio Benitez
7b48ca7103
Add optional input for IntoOutcome. Add mapper methods to Outcome.
...
This is a breaking change to `IntoOutcome`.
The MsgPack and JSON types now use `into_outcome` to generate the final
`Outcome` from their `FromData` implementations.
Resolves #98 .
2017-04-18 21:56:21 -07:00
Roman Frołow
8555a0fad5
Fix typo in Template documentation: words -> works.
2017-04-18 19:52:18 -07:00
Joshua Rombauer
0e759edf78
Implement 'From<T>' for 'Stream<T>' instead of custom 'from'.
...
Closes #267 .
2017-04-18 18:18:37 -07:00
Sergio Benitez
d6e86be1b0
Make route collisions a hard error.
...
This is a breaking change. Previously, route collisions were warnings.
2017-04-18 17:42:44 -07:00
Sergio Benitez
f97b02dda6
Note the extras in the config example.
2017-04-18 17:32:32 -07:00
Sergio Benitez
1524b9a6b2
Document size limits.
2017-04-18 00:36:39 -07:00
Sergio Benitez
6dc21e5380
Add support for configurable size limits.
2017-04-18 00:25:13 -07:00
Sergio Benitez
e6bbeacb1c
New version: 0.2.6.
2017-04-17 16:21:56 -07:00
Sergio Benitez
3c51d30e66
Avoid collision in FromForm derive by using weird names.
...
Fixes #265 .
2017-04-17 16:11:44 -07:00
Sergio Benitez
a1c4cc2224
Improve display of table config value.
2017-04-17 00:34:47 -07:00
Sergio Benitez
90c6636821
Remove duplication in site README.
2017-04-16 21:29:15 -07:00
Sergio Benitez
b5ef6ec85b
Add site contents, including the guide. Add license information.
2017-04-16 21:11:41 -07:00
Sergio Benitez
9b7f58448a
New version: 0.2.5.
2017-04-16 14:29:04 -07:00
Sergio Benitez
8a789c5d04
Update minimum nightly version in codegen.
2017-04-16 14:23:34 -07:00
Sergio Benitez
08fbe06b10
Fix lints for latest nightly.
2017-04-16 14:13:18 -07:00
Sergio Benitez
73e39dcf17
Fix small typo: It -> In.
2017-04-16 00:59:52 -07:00
Sergio Benitez
586d46ae9c
Use upstream smallvec.
2017-04-15 19:03:40 -07:00
Sergio Benitez
7d2a114280
Set version of managed_queue example to 0.0.0.
2017-04-14 14:58:17 -07:00
Sergio Benitez
8d14cd571c
Tidy up managed_queue example.
2017-04-14 14:54:19 -07:00
Stephan Buys
b4586f62ee
Add managed_queue example and tests.
2017-04-14 14:54:14 -07:00
Sergio Benitez
e6615af7e6
Add tests for pastebin example.
2017-04-14 14:39:17 -07:00
Sergio Benitez
e6203a77e7
Compile with 4 codegen units on dev.
2017-04-14 14:35:34 -07:00
Sergio Benitez
6641e9b92d
Add Response::content_type() method.
2017-04-14 14:35:22 -07:00
Sergio Benitez
3bebdcc53d
Add Response::body_string(). Use it in all tests.
2017-04-14 01:59:28 -07:00
Sergio Benitez
0d674c57fd
Return `HeaderMap` from Response::headers(). Remove Response::header_values().
...
This is a breaking change. A call to `Response::headers()` can be
replaced with `Response::headers().iter()`. A call to
`Response::header_values()` can be replaced with
`Response::headers().get()`.
2017-04-14 01:21:06 -07:00
Sergio Benitez
2e54a1f74d
Don't use &str where RawStr is now preferred.
2017-04-14 00:43:57 -07:00
Fabrice Desré
da1f6264e4
Enable the "tls" feature in the hello_tls example.
2017-04-13 17:38:56 -07:00
Sergio Benitez
a25a3c69c6
Cache parsed ContentType and Accept headers.
...
This is a breaking change. `Request::content_type` now returns a borrow
to `ContentType`. `FromRequest` for `ContentType` is no longer
implemented. Instead, `FromRequest` for `&ContentType` is implemented.
2017-04-13 02:44:47 -07:00
Sergio Benitez
e50164115b
Only emit TLS disabled error on misconfig.
2017-04-13 01:30:48 -07:00
Sergio Benitez
6f29696b4f
Make TLS misconfig an error. Always print launch message.
2017-04-13 01:16:09 -07:00
Sergio Benitez
1516ca4fb6
Initial TLS support.
...
This commit introduces TLS support, provided by `rustls` and a fork of
`hyper-rustls`. TLS support is enabled via the `tls` feature and
activated when the `tls` configuration parameter is set. A new
`hello_tls` example illustrates its usage.
This commit also introduces more robust and complete configuration
settings via environment variables. In particular, quoted string,
array, and table (dictionaries) based configuration parameters can now
be set via environment variables.
Resolves #28 .
2017-04-13 00:18:31 -07:00
Sergio Benitez
cf47daa8e1
Return 404 on missing static file in todo example.
2017-04-12 02:58:45 -07:00
Sergio Benitez
a2a0aab541
Depend on cookie >= 0.7.4 for ring bugfix.
2017-04-11 16:56:10 -07:00
Sergio Benitez
82ec8ee739
Use bash from env, not /usr/bin.
2017-04-06 22:04:32 -07:00
Sergio Benitez
982997dbad
Add Rocket::routes() method to get all routes. Add some internal benchmarks.
2017-04-05 01:19:33 -07:00
Sergio Benitez
5259e3fd5c
Disallow invalid form field names.
2017-04-04 17:00:48 -07:00
Sergio Benitez
7c19bf784d
Allow form field renaming via #[form(field = "name")] attribute.
2017-04-03 19:06:30 -07:00
Sergio Benitez
351658801e
Allow unreachable_code in generated route functions for new ! error types.
2017-04-03 16:46:13 -07:00
Sergio Benitez
f5ec470a7d
Use the `RawStr` type for raw parameter strings.
...
This is a breaking change.
The `&str` type no longer implements `FromParam`. The `&RawStr` type
should be used in its place.
2017-03-31 00:18:58 -07:00
Sergio Benitez
cff9901940
Implement FromData for Vec<u8>.
2017-03-30 23:17:28 -07:00
Sergio Benitez
0c44e44641
Use the `RawStr` type for all form raw strings.
...
This is a breaking change.
This commit introduces `RawStr` to forms. In particular, after this
commit, the `&str` type no longer implements `FromFormValue`, and so it
cannot be used as a field in forms. Instad, the `&RawStr` can be used.
The `FormItems` iterator now returns an `(&RawStr, &RawStr)` pair.
2017-03-30 23:06:53 -07:00
Sergio Benitez
f57d984e2e
New version: 0.2.4.
2017-03-30 19:56:12 -07:00
Sergio Benitez
f7bc1ce24f
Update codegen for latest nightly.
2017-03-30 19:56:12 -07:00
Sergio Benitez
10306c3b7e
Clarify segment handling for '..'.
2017-03-30 18:15:36 -07:00
Sergio Benitez
df19ef74db
Add RawStr::url_decode.
2017-03-30 18:15:15 -07:00
Sergio Benitez
709acf18a4
Initial implementation of RawStr.
2017-03-30 17:56:24 -07:00
Sergio Benitez
b49c89af7a
Rename UncasedAscii and UncasedAsciiRef to Uncased and UncasedStr.
2017-03-30 15:38:51 -07:00