axum/axum-core/CHANGELOG.md

96 lines
3.9 KiB
Markdown
Raw Normal View History

# Changelog
All notable changes to this project will be documented in this file.
The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/),
and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html).
# Unreleased
2022-05-02 11:52:24 +02:00
- None.
# 0.2.4 (02. May, 2022)
- **added:** Implement `IntoResponse` and `IntoResponseParts` for `http::Extensions` ([#975])
- **added:** Implement `IntoResponse` for `(http::response::Parts, impl IntoResponse)` ([#950])
- **added:** Implement `IntoResponse` for `(http::response::Response<()>, impl IntoResponse)` ([#950])
- **added:** Implement `IntoResponse for (Parts | Request<()>, $(impl IntoResponseParts)+, impl IntoResponse)` ([#980])
[#950]: https://github.com/tokio-rs/axum/pull/950
[#975]: https://github.com/tokio-rs/axum/pull/975
[#980]: https://github.com/tokio-rs/axum/pull/980
2022-04-26 16:19:47 +02:00
# 0.2.3 (25. April, 2022)
- **added:** Add `response::ErrorResponse` and `response::Result` for
`IntoResponse`-based error handling ([#921])
[#921]: https://github.com/tokio-rs/axum/pull/921
2022-04-19 16:17:52 +02:00
# 0.2.2 (19. April, 2022)
- **added:** Add `AppendHeaders` for appending headers to a response rather than overriding them ([#927])
[#927]: https://github.com/tokio-rs/axum/pull/927
2022-04-03 20:21:16 +02:00
# 0.2.1 (03. April, 2022)
- **added:** Add `RequestParts::extract` which allows applying an extractor as a method call ([#897])
[#897]: https://github.com/tokio-rs/axum/pull/897
2022-03-31 20:36:12 +02:00
# 0.2.0 (31. March, 2022)
- **added:** Add `IntoResponseParts` trait which allows defining custom response
types for adding headers or extensions to responses ([#797])
- **breaking:** Using `HeaderMap` as an extractor will no longer remove the headers and thus
they'll still be accessible to other extractors, such as `axum::extract::Json`. Instead
`HeaderMap` will clone the headers. You should prefer to use `TypedHeader` to extract only the
headers you need ([#698])
This includes these breaking changes:
- `RequestParts::take_headers` has been removed.
- `RequestParts::headers` returns `&HeaderMap`.
- `RequestParts::headers_mut` returns `&mut HeaderMap`.
- `HeadersAlreadyExtracted` has been removed.
- The `HeadersAlreadyExtracted` variant has been removed from these rejections:
- `RequestAlreadyExtracted`
- `RequestPartsAlreadyExtracted`
2022-01-25 09:46:26 +01:00
- `<HeaderMap as FromRequest<_>>::Rejection` has been changed to `std::convert::Infallible`.
- **breaking:** `axum::http::Extensions` is no longer an extractor (ie it
doesn't implement `FromRequest`). The `axum::extract::Extension` extractor is
_not_ impacted by this and works the same. This change makes it harder to
accidentally remove all extensions which would result in confusing errors
elsewhere ([#699])
This includes these breaking changes:
- `RequestParts::take_extensions` has been removed.
- `RequestParts::extensions` returns `&Extensions`.
- `RequestParts::extensions_mut` returns `&mut Extensions`.
- `RequestAlreadyExtracted` has been removed.
2022-01-25 09:46:26 +01:00
- `<Request as FromRequest>::Rejection` is now `BodyAlreadyExtracted`.
- `<http::request::Parts as FromRequest>::Rejection` is now `Infallible`.
- `ExtensionsAlreadyExtracted` has been removed.
- **breaking:** `RequestParts::body_mut` now returns `&mut Option<B>` so the
body can be swapped ([#869])
[#698]: https://github.com/tokio-rs/axum/pull/698
[#699]: https://github.com/tokio-rs/axum/pull/699
[#797]: https://github.com/tokio-rs/axum/pull/797
[#869]: https://github.com/tokio-rs/axum/pull/869
# 0.1.2 (22. February, 2022)
- **added:** Implement `IntoResponse` for `bytes::BytesMut` and `bytes::Chain<T, U>` ([#767])
[#767]: https://github.com/tokio-rs/axum/pull/767
# 0.1.1 (06. December, 2021)
- **added:** `axum_core::response::Response` now exists as a shorthand for writing `Response<BoxBody>` ([#590])
[#590]: https://github.com/tokio-rs/axum/pull/590
# 0.1.0 (02. December, 2021)
- Initial release.