mirror of
https://github.com/tokio-rs/axum.git
synced 2026-08-25 00:00:23 +02:00
Remove tower from axum's public API (#229)
Instead rely on `tower-service` and `tower-layer`. `tower` itself is only used internally. Fixes https://github.com/tokio-rs/axum/issues/186
This commit is contained in:
+3
-1
@@ -1,5 +1,6 @@
|
||||
#![allow(clippy::blacklisted_name)]
|
||||
|
||||
use crate::BoxError;
|
||||
use crate::{
|
||||
extract,
|
||||
handler::{any, delete, get, on, patch, post, Handler},
|
||||
@@ -23,7 +24,8 @@ use std::{
|
||||
task::{Context, Poll},
|
||||
time::Duration,
|
||||
};
|
||||
use tower::{make::Shared, service_fn, BoxError, Service};
|
||||
use tower::{make::Shared, service_fn};
|
||||
use tower_service::Service;
|
||||
|
||||
mod get_to_head;
|
||||
mod handle_error;
|
||||
|
||||
+2
-4
@@ -1,10 +1,8 @@
|
||||
use super::*;
|
||||
use crate::{extract::OriginalUri, response::IntoResponse, Json};
|
||||
use serde_json::{json, Value};
|
||||
use tower::{limit::ConcurrencyLimitLayer, timeout::TimeoutLayer};
|
||||
|
||||
use crate::{extract::OriginalUri, response::IntoResponse, Json};
|
||||
|
||||
use super::*;
|
||||
|
||||
#[tokio::test]
|
||||
async fn basic() {
|
||||
let one = Router::new()
|
||||
|
||||
Reference in New Issue
Block a user