From 941241c5f097260f552dd988fa5292d872c823d9 Mon Sep 17 00:00:00 2001 From: Nikolay Kim Date: Sat, 20 Jul 2019 10:50:36 +0600 Subject: [PATCH] Remove unneeded actix-utils dependency --- actix-framed/Cargo.toml | 8 ++++---- actix-framed/changes.md | 5 +++++ actix-framed/src/app.rs | 9 ++++----- actix-framed/src/lib.rs | 7 +------ src/guard.rs | 2 +- 5 files changed, 15 insertions(+), 16 deletions(-) diff --git a/actix-framed/Cargo.toml b/actix-framed/Cargo.toml index 5fbd262d0..321041c7e 100644 --- a/actix-framed/Cargo.toml +++ b/actix-framed/Cargo.toml @@ -1,6 +1,6 @@ [package] name = "actix-framed" -version = "0.2.0" +version = "0.2.1" authors = ["Nikolay Kim "] description = "Actix framed app server" readme = "README.md" @@ -21,11 +21,10 @@ path = "src/lib.rs" [dependencies] actix-codec = "0.1.2" -actix-service = "0.4.0" -actix-utils = "0.4.0" +actix-service = "0.4.1" actix-router = "0.1.2" actix-rt = "0.2.2" -actix-http = "0.2.0" +actix-http = "0.2.7" actix-server-config = "0.1.2" bytes = "0.4" @@ -36,3 +35,4 @@ log = "0.4" actix-server = { version = "0.6.0", features=["ssl"] } actix-connect = { version = "0.2.0", features=["ssl"] } actix-http-test = { version = "0.2.4", features=["ssl"] } +actix-utils = "0.4.4" diff --git a/actix-framed/changes.md b/actix-framed/changes.md index 9f16c790a..6e67e00d8 100644 --- a/actix-framed/changes.md +++ b/actix-framed/changes.md @@ -1,5 +1,10 @@ # Changes +## [0.2.1] - 2019-07-20 + +* Remove unneeded actix-utils dependency + + ## [0.2.0] - 2019-05-12 * Update dependencies diff --git a/actix-framed/src/app.rs b/actix-framed/src/app.rs index a9d73a25c..ad5b1ec26 100644 --- a/actix-framed/src/app.rs +++ b/actix-framed/src/app.rs @@ -6,7 +6,6 @@ use actix_http::{Error, Request, Response}; use actix_router::{Path, Router, Url}; use actix_server_config::ServerConfig; use actix_service::{IntoNewService, NewService, Service}; -use actix_utils::cloneable::CloneableService; use futures::{Async, Future, Poll}; use crate::helpers::{BoxedHttpNewService, BoxedHttpService, HttpNewService}; @@ -100,7 +99,7 @@ where type Response = (); type Error = Error; type InitError = (); - type Service = CloneableService>; + type Service = FramedAppService; type Future = CreateService; fn new_service(&self, _: &ServerConfig) -> Self::Future { @@ -138,7 +137,7 @@ impl Future for CreateService where T: AsyncRead + AsyncWrite, { - type Item = CloneableService>; + type Item = FramedAppService; type Error = (); fn poll(&mut self) -> Poll { @@ -177,10 +176,10 @@ where } router }); - Ok(Async::Ready(CloneableService::new(FramedAppService { + Ok(Async::Ready(FramedAppService { router: router.finish(), state: self.state.clone(), - }))) + })) } else { Ok(Async::NotReady) } diff --git a/actix-framed/src/lib.rs b/actix-framed/src/lib.rs index 5e72ba5ba..250533f39 100644 --- a/actix-framed/src/lib.rs +++ b/actix-framed/src/lib.rs @@ -1,9 +1,4 @@ -#![allow( - clippy::type_complexity, - clippy::new_without_default, - dead_code, - deprecated -)] +#![allow(clippy::type_complexity, clippy::new_without_default, dead_code)] mod app; mod helpers; mod request; diff --git a/src/guard.rs b/src/guard.rs index 6fd6d1d2c..e0b4055ba 100644 --- a/src/guard.rs +++ b/src/guard.rs @@ -26,7 +26,7 @@ //! ``` #![allow(non_snake_case)] -use actix_http::http::{self, header, HttpTryFrom, uri::Uri}; +use actix_http::http::{self, header, uri::Uri, HttpTryFrom}; use actix_http::RequestHead; /// Trait defines resource guards. Guards are used for routes selection.