Tobias Bieniek and GitHub
8def6782fb
Replace custom BoxCloneService struct with tower::util::BoxCloneSyncService ( #3109 )
2024-12-27 08:57:52 +01:00
Jonas Platte and GitHub
85b6fd49c7
Upgrade most example dependencies ( #2936 )
2024-09-27 18:50:52 +02:00
Jonas Platte and GitHub
2fb6cea732
Remove unused dependencies from examples ( #2934 )
2024-09-25 03:44:47 -04:00
Weipeng Hong and GitHub
ef1448a3f5
Use env!("CARGO_CRATE_NAME") in the example to simplify the tracing setup code ( #2884 )
2024-08-24 08:36:08 +02:00
mikihiro and GitHub
c6fd852844
Update sync_wrapper to 1.0.0 from 0.1.1
...
... and fix CI.
2024-03-23 19:46:20 +01:00
Rdbo and GitHub
530aa5530c
Fix typos in testing example ( #2542 )
2024-01-26 21:17:40 +00:00
David Pedersen
9d0e634285
Fix comment in testing example
2023-11-27 10:58:03 +01:00
David Pedersen and GitHub
e63cc49f55
Update unix-domain-socket, listen-multiple-addrs, and testing examples ( #2358 )
2023-11-27 10:23:52 +01:00
43b14a5f02
Update to latest versions of hyper and http-body ( #1882 )
...
Co-authored-by: Michael Scofield <[email protected] >
Co-authored-by: Jonas Platte <[email protected] >
2023-11-23 11:03:03 +00:00
Yuri Astrakhan and GitHub
786329d85d
Use inline format args ( #2232 )
2023-09-19 06:51:57 +00:00
Raphael Nestler and GitHub
b20e66e79a
Remove unnecessary allow(dead_code) from testing example ( #2117 )
2023-07-25 17:30:19 +00:00
David Pedersen
c97967252d
Add serve function and remove Server re-export ( #1868 )
2023-04-21 17:45:31 +02:00
6703f8634c
Remove B type param: Follow ups ( #1789 )
...
Co-authored-by: Jonas Platte <[email protected] >
Co-authored-by: Michael Scofield <[email protected] >
2023-04-21 17:45:31 +02:00
4e4c29175f
Remove B type param ( #1751 )
...
Co-authored-by: Jonas Platte <[email protected] >
Co-authored-by: Michael Scofield <[email protected] >
2023-04-21 17:45:31 +02:00
David Pedersen and GitHub
f726f16b6d
Update to tower-http 0.4 ( #1783 )
2023-02-24 20:51:30 +00:00
David Pedersen and GitHub
143c415955
Add MockConnectInfo ( #1767 )
2023-02-17 13:09:29 +01:00
tottoto and GitHub
6c133be5b7
Refactor initializing tracing-subscriber in examples ( #1596 )
...
* Refactor initializing tracing-subscriber
* Revert "Refactor initializing tracing-subscriber"
This reverts commit 0876260bf9 in favor of tracing_subscriber::registry.
* Use EnvFilter::try_from_default_env in chat example
* Use EnvFilter::try_from_default_env in examples
2022-11-30 10:46:19 +01:00
David Pedersen and GitHub
0b26411f39
Change Router::with_state and impl Service for Router<()> ( #1552 )
...
* Implement `Service` for `Router<(), B>`
* wip
* wip
* fix some tests
* fix examples
* fix doc tests
* clean up docs
* changelog
* fix
* also call `with_state` when converting `MethodRouter` into a `MakeService`
* suggestions from review
2022-11-24 14:43:10 +00:00
Jonas Platte and GitHub
69d64cecc3
Split RouterService off of Router ( #1381 )
2022-09-22 12:10:55 +02:00
azzamsa and GitHub
a3eaa332e4
test: use ready() and call() to avoid using clone() ( #1176 )
2022-07-20 12:19:15 +00:00
David Pedersen and GitHub
93251fa203
Bump MSRV to 1.56 and update to the 2021 edition ( #1098 )
2022-06-17 20:11:35 +02:00
David Pedersen and GitHub
968ee44631
Sort dependencies in Cargo.tomls ( #1076 )
...
* sort dependencies
* check sorted deps on CI
* this should fail
* does caching matter?
* fix sorting
2022-06-10 08:59:17 +02:00
David Pedersen and GitHub
79f6cde3b1
Update to tower-http 0.3.0 ( #965 )
...
* Update to tower-http 0.3.0
* changelog link
2022-04-25 14:59:16 +00:00
Jonas Platte and GitHub
79b94b9bd6
Replace set_var usage in examples ( #829 )
...
* examples: Fix inconsistent toml formatting
* examples: Replace set_var usage
2022-03-06 12:37:00 +01:00
David Pedersen and GitHub
66c5142d0c
Update tower-http ( #581 )
...
Updates to 0.2 which was just published.
2021-12-01 20:14:25 +00:00
Pure White and GitHub
5a5800c1ae
feat: default to charset=utf-8 for text content type ( #554 )
...
* feat: default to charset=utf-8 for text content type
* added changelog && fix comment
* fix workflow
2021-11-25 08:31:30 +00:00
Jonas Platte and GitHub
9c77ee0295
Use nightly clippy & rustfmt for more style checks ( #487 )
2021-11-09 11:53:57 +00:00
EdorianDark and GitHub
513c5a694d
Update tracing-subscriber to 0.3 ( #472 )
...
Fixes #469
2021-11-06 14:50:23 +00:00
David Pedersen and GitHub
ba4d8a2357
Move axum crate into workspace subfolder ( #458 )
...
* Move axum crate into workspace subfolder
Over time I imagine we're gonna have other crates in this repo that
provide utilities or integrations for axum. This prepares for that by
moving the main axum crate into its own folder.
The README situation is a bit annoying because we want `./README.md`
for viewing the repo on github but `axum/README.md` for crates.io. For
now I've just copy/pasted it and added CI step to make sure they're
identical.
* update changelog link
* Add licenses to all examples
* is this how you install `diff`?
* or maybe this is how?
* fix readme links
* like this?
* fix cargo-deny step
* Try making root readme a symlink
* remove compare readme step
not needed since readme in repo root is now a symlink
* Revert "Add licenses to all examples"
This reverts commit ab321b7fb9 .
2021-11-03 12:38:48 +01:00
David Pedersen and GitHub
7692baf837
Reorganize method routers for handlers and services ( #405 )
...
* Re-organize method routing for handlers
* Re-organize method routing for services
* changelog
2021-10-24 20:05:16 +00:00
David Pedersen and GitHub
0ee7379d4f
Fix compile time regression by boxing routes internally ( #404 )
...
This is a reimplementation of #401 but with the new matchit based router.
Fixes #399
2021-10-24 20:52:42 +02:00
Andrei Zolkin and GitHub
9df57e6ff2
Migrate all examples to use std::env::var_os ( #312 )
2021-09-12 17:39:43 +02:00
David Pedersen and GitHub
ca4d9a2bb9
Replace route with Router::new().route() ( #215 )
...
This way there is now only one way to create a router:
```rust
use axum::{Router, handler::get};
let app = Router::new()
.route("/foo", get(handler))
.route("/foo", get(handler));
```
`nest` was changed in the same way:
```rust
use axum::Router;
let app = Router::new().nest("/foo", service);
```
2021-08-19 22:37:48 +02:00
David Pedersen and GitHub
97b53768ba
Replace RoutingDsl trait with Router type ( #214 )
...
* Remove `RoutingDsl`
* Fix typo
2021-08-19 21:24:32 +02:00
David Pedersen and GitHub
6c9651c14a
Move all examples to their own crates ( #201 )
...
This makes it much clearer which dependencies each example has.
2021-08-18 00:49:01 +02:00