Commit Graph
100 Commits
Author SHA1 Message Date
Jonas Platte a0f310a492 Make into_future on Serve, WithGracefulShutdown independent of tokio (#2975) 2024-10-11 10:57:05 +02:00
Jonas Platte d783a8b17e Add matchit upgrade to axum changelog 2024-10-05 11:44:31 +00:00
Jonas Platte 47791cb593 Remove versions from internal dev-dependencies
This breaks the cyclic dependencies for publishing.
2024-10-05 11:44:31 +00:00
Jonas Platte 9a69e415fb Release axum 0.8.0-alpha.1 and related crates (#2958) 2024-10-05 11:20:05 +02:00
Jonas Platte 20a0624795 Replace Router::{map_inner, tap_inner_mut} by macros (#2954) 2024-10-04 17:00:50 +00:00
Jonas Platte 5db62e8452 Remove examples/listen-multiple-addrs (#2951) 2024-09-30 23:23:19 +02:00
Jonas Platte 928d31d1d7 ci: Only save cache from main (#2946) 2024-09-29 21:15:49 +00:00
Jonas Platte fb4b1899eb Remove mutexes around boxed services (#2947) 2024-09-29 21:04:31 +02:00
Jonas Platte 3df15fd2ea Update mongodb example (#2944) 2024-09-28 23:40:52 +02:00
Jonas Platte dda5a273b5 README updates (#2945) 2024-09-28 23:23:22 +02:00
Jonas Platte 689ca1aea2 Update MSRV for all crates to 1.75 (#2943) 2024-09-28 21:21:41 +00:00
Jonas Platte 5d8541de6e Remove duplication in serving with and without graceful shutdown (#2803) 2024-09-27 23:16:54 +02:00
Jonas Platte 4b48f308c3 Merge branch 'v0.7.x' into main 2024-09-27 22:37:09 +02:00
Jonas Platte fe56a310ef Bump versions 2024-09-27 22:36:28 +02:00
Jonas Platte ac50d7daaf docs: Remove manual tables of content (#2921) 2024-09-27 21:24:08 +02:00
Jonas Platte 6f5607785d core: Fix compile errors from __log_rejection (#2933) 2024-09-27 21:22:59 +02:00
Jonas Platte 4fc0641874 Upgrade private dependencies (#2935) 2024-09-27 21:22:29 +02:00
Jonas Platte 0a0e438a8b docs: Remove manual tables of content (#2921) 2024-09-27 21:16:17 +02:00
Jonas Platte 85b6fd49c7 Upgrade most example dependencies (#2936) 2024-09-27 18:50:52 +02:00
Jonas Platte 2fb6cea732 Remove unused dependencies from examples (#2934) 2024-09-25 03:44:47 -04:00
Jonas Platte 391f2deccd core: Fix compile errors from __log_rejection (#2933) 2024-09-25 03:44:35 -04:00
Jonas Platte ef50e5c180 Upgrade private dependencies (#2935) 2024-09-24 23:50:53 +02:00
Jonas Platte 712b3ef24b Merge branch 'v0.7.x' into main 2024-09-20 21:27:30 +02:00
Jonas Platte a73dab417d Bump versions 2024-09-20 21:25:30 +02:00
Jonas PlatteandYann Simon 0ba73b5c6e Implement FromRequest for BytesMut (#2583)
Co-authored-by: Yann Simon <[email protected]>
2024-09-20 20:57:26 +02:00
Jonas Platte 88de9fc407 ci: Add more allowances for multiple version of the same crate 2024-09-20 20:57:17 +02:00
Jonas Platte d2d74f6ad1 Upgrade tower and tower-http 2024-09-20 20:57:12 +02:00
Jonas PlatteandYann Simon 352b7cf044 Implement FromRequest for BytesMut (#2583)
Co-authored-by: Yann Simon <[email protected]>
2024-09-20 20:36:00 +02:00
Jonas Platte 69fac0a065 ci: Add more allowances for multiple version of the same crate 2024-09-20 20:34:07 +02:00
Jonas Platte 652e59b0c0 Upgrade tower and tower-http 2024-09-20 20:34:07 +02:00
Jonas Platte de9290a8b7 Add more must_use attributes (#2846)
… so people get a warning when they accidentally add a semicolon after the response expression in a handler function.

Also update changelogs of axum-core, axum-extra.
2024-09-12 12:09:21 +02:00
Jonas Platte b214e39581 Add more must_use attributes (#2846)
… so people get a warning when they accidentally add a semicolon after the response expression in a handler function.

Also update changelogs of axum-core, axum-extra.
2024-09-11 19:17:25 +00:00
Jonas Platte fdf83d0b73 Bring back the breaking changes readme section (#2804) 2024-09-11 20:42:15 +02:00
Jonas Platte 8b1cad656f Bump nightly version used for ui tests (#2805) 2024-09-11 20:41:44 +02:00
Jonas Platte 89202ac379 Replace own TowerToHyperService with upstream version (#2692) 2024-06-09 20:18:03 +02:00
Jonas PlatteandLogan Nielsen 34e11c50b5 Add Extension<NonCloneType> debug_handler ui test (#2731)
Co-authored-by: Logan Nielsen <[email protected]>
2024-06-09 20:17:43 +02:00
Jonas Platte 80afd9253d Add scope doc alias for Router::nest (#2756) 2024-06-09 20:15:31 +02:00
Jonas Platte 5201798d4e Enable diagnostic attributes for Rust 1.78+ (#2693) 2024-04-30 11:05:38 -04:00
Jonas Platte 4d65ba0215 ci: Unbreak cargo-deny action (#2613) 2024-02-22 09:59:05 +01:00
Jonas Platte 5f7fcc5866 Fix blocking-mode tcp listener in auto-reload example (#2558) 2024-01-31 14:55:42 +00:00
Jonas Platte af13c53938 Make Router Sync without breaking the API (#2481) 2024-01-02 20:18:07 +01:00
Jonas Platte 906f803a20 Update changelog (#2349) 2023-11-25 18:34:04 +01:00
Jonas Platte 4d681de0dd Clean up Q&A discussion template (#2342) 2023-11-24 14:13:56 +01:00
Jonas Platte 92253fe7b3 Fix error in Q&A discussion template (#2341) 2023-11-24 12:21:13 +01:00
Jonas Platte 9a931605dd GitHub: Add a Q&A discussion template (#2340) 2023-11-24 11:57:17 +01:00
Jonas Platte e84d563b26 Improve documentation of axum::Form (#2289) 2023-10-26 06:37:19 +09:00
Jonas Platte 3f5c907e2d Add auto-reload example (#2166) 2023-09-11 13:56:47 +02:00
Jonas Platte 24f0f3eae8 Remove unused mut 2023-08-22 12:22:45 +02:00
Jonas Platte 11b24f7898 Remove redundant bindings 2023-08-22 12:22:45 +02:00
Jonas Platte e84a67e568 Fix documentation for MethodRouter::into_make_service (#2176) 2023-08-15 15:26:53 +00:00
Jonas Platte 4120195c53 Check for typos in CI 2023-08-08 11:27:45 +02:00
Jonas Platte 34d1fbc052 Fix typos found by crate-ci/typos 2023-08-08 11:27:45 +02:00
Jonas Platte ff3884aa41 Silence error from enabling nightly_error_messages 2023-08-08 11:27:45 +02:00
Jonas Platte 432289dd04 Replace :emoji: codes with the actual emoji (#2144) 2023-08-03 08:23:18 +00:00
Jonas Platte 8af38763a5 Implement Clone for ErasedJson (#2142) 2023-08-02 19:35:04 +00:00
Jonas PlatteandDavid Pedersen 43b2d52403 Add OptionalPath extractor (#1889)
Co-authored-by: David Pedersen <[email protected]>
2023-04-09 12:23:13 +00:00
Jonas Platte eec4195eac Fix broken links in the documentation (#1878) 2023-03-23 14:55:56 +00:00
Jonas Platte 2600c22703 Make tracing-aka-logging example more realistic (#1869) 2023-03-21 11:17:31 +01:00
Jonas Platte f65fa22f34 Improve tower-http doc links (#1842) 2023-03-12 11:15:58 +01:00
Jonas PlatteandDavid Pedersen dc480f7b0e Re-integrate examples into the root workspace (#1466)
Co-authored-by: David Pedersen <[email protected]>
2023-03-10 12:02:11 +01:00
Jonas PlatteandDavid Pedersen a26ddd1063 Improve debug_handler message for generic request-consuming extractors (#1826)
Co-authored-by: David Pedersen <[email protected]>
2023-03-10 08:51:03 +00:00
Jonas PlatteandDavid Pedersen 43883b8d9b Replace weird doc paragraph by compiler-checked must_use attribute (#1801)
Co-authored-by: David Pedersen <[email protected]>
2023-03-03 08:54:38 +00:00
Jonas Platte 2c9d2dea0e Upgrade dependencies (#1746) 2023-02-11 23:36:40 +00:00
Jonas Platte 19596584da Update trybuild output 2023-01-30 21:47:57 +01:00
Jonas Platte bdfaedb344 Use call-site span for future Send check in debug_handler 2023-01-30 21:47:57 +01:00
Jonas Platte 7ecf8bd6cf Use implicit format-args captures where applicable (#1709) 2023-01-20 12:04:49 +01:00
Jonas Platte cad6611bf7 Update deny.toml bans (#1668) 2023-01-03 19:53:17 +01:00
Jonas Platte 1ff5ab5ba2 Add emoji for contact links (new issue page) 2022-12-09 11:00:00 +01:00
Jonas Platte 15b6f8cc70 Add "I have looked for existing issues" checkbox to issue templates (#1632) 2022-12-09 09:30:25 +00:00
Jonas Platte b372244099 Guide people to the right places to ask questions (#1631)
* README: Link to discussions instead of issues in Getting Help section

* Link to Discussions and Discord on new issue page
2022-12-09 10:14:31 +01:00
Jonas Platte 8d2fb3618e Remove unused imports from doctest (#1551) 2022-11-20 01:41:50 +01:00
Jonas Platte ce8ea56f3b Small improvements to RouterService (#1548)
* Fix docstrings on RouterService methods

* Simplify signatures of RouterService methods with Self type
2022-11-19 22:26:12 +01:00
Jonas Platte c3fa0b2a3e Fix unused variable warning when developing using a nightly toolchain (#1520) 2022-11-10 12:41:16 +01:00
Jonas Platte 944f388ae0 Add missing cfg's for signed cookie tests 2022-11-05 11:33:27 +01:00
Jonas Platte 36f24990c8 Fix clippy lints 2022-11-05 11:33:27 +01:00
Jonas Platte 21475f94ff Adjust renamed clippy lint name 2022-11-05 11:33:27 +01:00
Jonas Platte beb5ebbe8a Update deny.toml (#1488) 2022-10-20 16:51:52 +02:00
Jonas Platte b378fb283f Add Error::into_inner (#1476) 2022-10-13 11:44:54 +02:00
Jonas Platte a2ab338e68 Rewrite how state is passed from Router to MethodRouter 2022-10-09 19:33:40 +00:00
Jonas Platte 7cbacd1433 Improve the error message for state type inference failure in FromRequest(Parts) derive macro (#1432)
* Add a dedicated error message for state type inference issues

* Generate valid code even if state type can't be inferred

* Also error on state type inference for debug_handler
2022-10-09 20:25:05 +02:00
Jonas Platte a7d8954178 Use RequestPartsExt more in docs / examples (#1445)
* Use RequestPartsExt more in docs / examples

* Remove unused import
2022-10-04 17:26:51 +00:00
Jonas PlatteandDavid Pedersen b94248191e Add RequestExt::{with_limited_body, into_limited_body} (#1420)
* Move RequestExt and RequestPartsExt into axum-core

* Add RequestExt::into_limited_body

… and use it for Bytes extraction.

* Add RequestExt::with_limited_body

… and use it for Multipart extraction.

Co-authored-by: David Pedersen <[email protected]>
2022-09-28 20:20:47 +00:00
Jonas Platte 410fd49aa9 Fix Cached<T> as the last argument of a handler function (#1428)
* Remove FromRequest impl for Cached<T>

* Add a test for Cached<T> as the last argument of a handler function
2022-09-28 09:06:15 +00:00
Jonas Platte 9196c09fe8 Merge handler::{WithState, IntoService} into one HandlerService type (#1418) 2022-09-26 14:51:42 +02:00
Jonas Platte 83ba8c3876 Remove *_boxed_response_body methods on MethodRouter (#1415)
They were identical to the methods without the prefix.
2022-09-25 16:26:18 +02:00
Jonas Platte 4847d681b1 Allow Routers to inherit state (#1368)
* Rename Fallback::Custom to Fallback::Service

* Allow Routers to inherit state

* Rename Router::{nest => nest_service} and add new nest method for Routers

* Fix lints

* Add basic tests for state inheritance

* Changelog
2022-09-25 11:56:23 +00:00
Jonas Platte e3a17c1249 Add #[track_caller] attribute to Router::into_[make_]service (#1407) 2022-09-23 21:10:08 +02:00
Jonas Platte 4c846488c2 Update expected stderr of trybuild test (#1402) 2022-09-22 18:36:31 +02:00
Jonas Platte 69d64cecc3 Split RouterService off of Router (#1381) 2022-09-22 12:10:55 +02:00
Jonas Platte 18e3fac5d3 Small routing module refactoring (#1364) 2022-09-22 12:10:32 +02:00
Jonas Platte 7105805ba2 Extend from_fn_with_state doctest (#1393) 2022-09-19 21:02:43 +02:00
Jonas Platte 4ade706ab0 Add track_caller to route_with_tsr (#1390)
… and route_service_with_tsr.
2022-09-18 23:12:08 +02:00
Jonas Platte c09ecefcab Use regular non-exhaustive debug representation instead of custom one (#1380) 2022-09-16 22:56:25 +02:00
Jonas Platte c8dbe5a7e9 Relax Multipart FromRequest implementation bounds (#1379) 2022-09-16 18:49:42 +00:00
Jonas Platte da4ea4d4c2 Add must_use attribute to Redirect type (#1356) 2022-09-07 13:52:58 +02:00
Jonas Platte 92f6b68390 Panic when attempting to add a route_layer to an empty router (#1327) 2022-08-25 15:42:17 +02:00
Jonas PlatteandDavid Pedersen 7705ef6661 Add #[derive(FromRequestParts)] (#1305)
* Add missing leading double colon

* Separate handling of last element in FromRequest derive

* FromRequestParts derive

* fix it and add lots of tests

* docs

* changelog

* Update axum-macros/src/lib.rs

Co-authored-by: Jonas Platte <[email protected]>

Co-authored-by: David Pedersen <[email protected]>
2022-08-23 19:14:02 +00:00
Jonas Platte 7795e649f6 Avoid unhelpful compiler suggestion (#1251) 2022-08-12 10:06:38 +00:00
Jonas Platte 7cbb7cf135 Use new Cargo features to avoid implicit features for optional dependencies (#1239)
* Fix changelog entry for MSRV change in axum-extra 0.3.5

* Bump MSRV to 1.60 for axum, axum-extra, axum-macros

* Use new Cargo features to avoid implicit features for optional dependencies
2022-08-09 18:43:02 +02:00
Jonas Platte f0f60681ef Fix intra-doc links on docs.rs (#1205)
* Use version 2 of Cargo's feature resolver

* Increase minimum version of tungstenite

Tungstenite 0.17.1 has a higher MSRV, and there should be no reason to
use it over 0.17.2.

* Clean up and fix MSRV CI job

* Fix some intra-doc links not resolving correctly on docs.rs

* Bump minimum version of tower

… to avoid dependencies with a broken minimum-versions chain.
2022-07-28 19:14:31 +02:00