mirror of
https://github.com/tokio-rs/axum.git
synced 2026-08-26 00:00:23 +02:00
axum 0.6 and friends 🎉 (#1570)
* changelog * bump versions * reorder changelogs a bit * Apply suggestions from code review Co-authored-by: Jonas Platte <[email protected]> * Expand fallback inheritance * Reword tsr * Mention `parse-body-based-on-content-type` example Co-authored-by: Jonas Platte <[email protected]>
This commit is contained in:
co-authored by
Jonas Platte
parent
0b26411f39
commit
1b6780cf6c
@@ -9,6 +9,21 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
|
||||
|
||||
- None.
|
||||
|
||||
# 0.3.0 (25. November, 2022)
|
||||
|
||||
- **added:** Added new `FromRequestParts` trait. See axum's changelog for more
|
||||
details ([#1272])
|
||||
- **breaking:** `FromRequest` has been reworked and `RequestParts` has been
|
||||
removed. See axum's changelog for more details ([#1272])
|
||||
- **breaking:** `BodyAlreadyExtracted` has been removed ([#1272])
|
||||
- **breaking:** `AppendHeaders` now works on any `impl IntoIterator` ([#1495])
|
||||
|
||||
[#1272]: https://github.com/tokio-rs/axum/pull/1272
|
||||
[#1495]: https://github.com/tokio-rs/axum/pull/1495
|
||||
|
||||
<details>
|
||||
<summary>0.3.0 Pre-Releases</summary>
|
||||
|
||||
# 0.3.0-rc.3 (8. November, 2022)
|
||||
|
||||
- **added:** Add `DefaultBodyLimit::max` for changing the default body limit ([#1397])
|
||||
@@ -47,6 +62,8 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
|
||||
[#1155]: https://github.com/tokio-rs/axum/pull/1155
|
||||
[#1272]: https://github.com/tokio-rs/axum/pull/1272
|
||||
|
||||
</details>
|
||||
|
||||
# 0.2.8 (10. September, 2022)
|
||||
|
||||
- **breaking:** Added default limit to how much data `Bytes::from_request` will
|
||||
|
||||
@@ -9,7 +9,7 @@ license = "MIT"
|
||||
name = "axum-core"
|
||||
readme = "README.md"
|
||||
repository = "https://github.com/tokio-rs/axum"
|
||||
version = "0.3.0-rc.3" # remember to also bump the version that axum depends on
|
||||
version = "0.3.0" # remember to also bump the version that axum depends on
|
||||
|
||||
[dependencies]
|
||||
async-trait = "0.1"
|
||||
@@ -25,7 +25,7 @@ tower-service = "0.3"
|
||||
rustversion = "1.0.9"
|
||||
|
||||
[dev-dependencies]
|
||||
axum = { path = "../axum", version = "0.6.0-rc.2" }
|
||||
axum = { path = "../axum", version = "0.6.0" }
|
||||
futures-util = "0.3"
|
||||
hyper = "0.14"
|
||||
tokio = { version = "1.0", features = ["macros"] }
|
||||
|
||||
@@ -66,8 +66,8 @@ use tower_layer::Layer;
|
||||
///
|
||||
/// [`Body::data`]: http_body::Body::data
|
||||
/// [`Bytes`]: bytes::Bytes
|
||||
/// [`Json`]: https://docs.rs/axum/0.6.0-rc.2/axum/struct.Json.html
|
||||
/// [`Form`]: https://docs.rs/axum/0.6.0-rc.2/axum/struct.Form.html
|
||||
/// [`Json`]: https://docs.rs/axum/0.6.0/axum/struct.Json.html
|
||||
/// [`Form`]: https://docs.rs/axum/0.6.0/axum/struct.Form.html
|
||||
/// [`FromRequest`]: crate::extract::FromRequest
|
||||
/// [`RequestBodyLimit`]: https://docs.rs/tower-http/latest/tower_http/limit/struct.RequestBodyLimit.html
|
||||
/// [`RequestExt::with_limited_body`]: crate::RequestExt::with_limited_body
|
||||
@@ -114,8 +114,8 @@ impl DefaultBodyLimit {
|
||||
///
|
||||
/// [`tower_http::limit`]: https://docs.rs/tower-http/0.3.4/tower_http/limit/index.html
|
||||
/// [`Bytes`]: bytes::Bytes
|
||||
/// [`Json`]: https://docs.rs/axum/0.6.0-rc.2/axum/struct.Json.html
|
||||
/// [`Form`]: https://docs.rs/axum/0.6.0-rc.2/axum/struct.Form.html
|
||||
/// [`Json`]: https://docs.rs/axum/0.6.0/axum/struct.Json.html
|
||||
/// [`Form`]: https://docs.rs/axum/0.6.0/axum/struct.Form.html
|
||||
pub fn disable() -> Self {
|
||||
Self {
|
||||
kind: DefaultBodyLimitKind::Disable,
|
||||
@@ -147,8 +147,8 @@ impl DefaultBodyLimit {
|
||||
/// ```
|
||||
///
|
||||
/// [`Bytes::from_request`]: bytes::Bytes
|
||||
/// [`Json`]: https://docs.rs/axum/0.6.0-rc.2/axum/struct.Json.html
|
||||
/// [`Form`]: https://docs.rs/axum/0.6.0-rc.2/axum/struct.Form.html
|
||||
/// [`Json`]: https://docs.rs/axum/0.6.0/axum/struct.Json.html
|
||||
/// [`Form`]: https://docs.rs/axum/0.6.0/axum/struct.Form.html
|
||||
pub fn max(limit: usize) -> Self {
|
||||
Self {
|
||||
kind: DefaultBodyLimitKind::Limit(limit),
|
||||
|
||||
@@ -37,7 +37,7 @@ mod private {
|
||||
///
|
||||
/// See [`axum::extract`] for more general docs about extraxtors.
|
||||
///
|
||||
/// [`axum::extract`]: https://docs.rs/axum/0.6.0-rc.2/axum/extract/index.html
|
||||
/// [`axum::extract`]: https://docs.rs/axum/0.6.0/axum/extract/index.html
|
||||
#[async_trait]
|
||||
#[cfg_attr(
|
||||
nightly_error_messages,
|
||||
@@ -106,7 +106,7 @@ pub trait FromRequestParts<S>: Sized {
|
||||
/// This ensures your extractor is as flexible as possible.
|
||||
///
|
||||
/// [`http::Request<B>`]: http::Request
|
||||
/// [`axum::extract`]: https://docs.rs/axum/0.6.0-rc.2/axum/extract/index.html
|
||||
/// [`axum::extract`]: https://docs.rs/axum/0.6.0/axum/extract/index.html
|
||||
#[async_trait]
|
||||
#[cfg_attr(
|
||||
nightly_error_messages,
|
||||
|
||||
Reference in New Issue
Block a user