v0.10.0
This release updates tide's Request
and Response
types to match http_types
's Request
and Response
, a new Server::listen_unix
method to listen on Unix Domain Sockets, and the ability to return json!
literals directly from endpoints.
Added
- Added
Server::listen_unix
#531 - Added
Request::peer_addr
#530 - Added
Request::local_addr
#530 - Added
Request::remote
#537 - Added
Request::host
#537 - Added
Request::header_mut
#537 - Added
Request::append_header
#537 - Added
Request::remove_header
#537 - Added
Request::iter
#537 - Added
Request::iter_mut
#537 - Added
Request::header_names
#537 - Added
Request::header_values
#537 - Added
Request::query
#537 - Added
Request::content_type
#537 - Added warning about domain/path inconsistencies to
remove_cookie
#533 - Added an optional
name
method toMiddleware
#545 - Added
AsRef/AsMut<Headers>
forRequest/Response
#553 - Added
Request::take_body
#550 - Added
Response::swap_body
#562 - Added
Response::iter
#550 - Added
Response::iter_mut
#550 - Added
Response::header_names
#550 - Added
Response::header_values
#550 - Added
Response::content_type
#550 - Added
Response::set_content_type
#550 - Added
Response::header_mut
#562 - Added
tide::{After, Before}
middleware constructors #556 - Added support for returning JSON literals from endpoints #523
Response::new
now acceptsu16
as well asStatusCode
as arguments #562- Added a new
convert
submodule which holds various conversion-related types, includingserde
#564
Changed
- Renamed
Request::uri
toRequest::url
#537 Request::body_bytes
now returnstide::Result
#537Request::body_string
now returnstide::Result
#537Request::body_json
now returnstide::Result
#537Request::body_form
now returnstide::Result
#537Request::set_ext
no longer takes and returnsSelf
#537- Use
http_types::mime
instead of themime
crate #536 - - Renamed
Reponse::set_cookie
toResponse::insert_cookie
#562 - Various
Response
methods no longer returnSelf
#562 - Renamed
Response::set_header
toResponse::insert_header
#562 - Renamed
Reponse::set_ext
toResponse::insert_ext
#562
Removed
- Removed
Response::redirect
in favor oftide::Redirect
#562 - Removed
Response::{body_string, body_form, body_json, body}
in favor ofResponse::set_body
#562
Fixed
- Update docs from
Request::local
toRequest::ext
#539 - Creating a middleware directly from a function is now possible again #545
- Fixed wildcard tests #518