Skip to content

Releases: tokio-rs/axum

axum-core - v0.2.0

31 Mar 19:07
fba2faa
Compare
Choose a tag to compare
  • 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
    • <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.
    • <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)

axum - v0.4.7

01 Mar 13:01
558a4d0
Compare
Choose a tag to compare
  • added: Implement tower::Layer for Extension (#801)
  • changed: Deprecate AddExtensionLayer. Use Extension instead (#805)

axum-macros - v0.1.2

01 Mar 13:23
Compare
Choose a tag to compare
  • fixed: Use fully qualified Result type (#796)

axum-extra - v0.1.5

01 Mar 13:20
Compare
Choose a tag to compare
  • added: Add TypedPath::to_uri for converting the path into a Uri (#790)

axum - v0.4.6

22 Feb 12:55
4b0b4c8
Compare
Choose a tag to compare
  • added: middleware::from_fn for creating middleware from async functions.
    This previously lived in axum-extra but has been moved to axum (#719)
  • fixed: Set Allow header when responding with 405 Method Not Allowed (#733)

axum-macros - v0.1.1

24 Feb 08:49
Compare
Choose a tag to compare
  • Add #[derive(TypedPath)] for use with axum-extra's new "type safe" routing API (#756)

axum-extra - v0.1.4

24 Feb 08:49
Compare
Choose a tag to compare
  • fix: Depend on the right versions of axum and axum-macros (#782)

axum-extra - v0.1.3

24 Feb 08:49
Compare
Choose a tag to compare
  • added: Add type safe routing. See axum_extra::routing::typed for more details (#756)
  • fix: Depend on tower with default_features = false (#666)
  • change: middleware::from_fn has been deprecated and moved into the main
    axum crate (#719)

axum-core - v0.1.2

24 Feb 08:48
Compare
Choose a tag to compare
  • added: Implement IntoResponse for bytes::BytesMut and bytes::Chain<T, U> (#767)

v0.4.5

31 Jan 21:30
cab7d67
Compare
Choose a tag to compare