1
0
mirror of https://github.com/fafhrd91/actix-net synced 2024-11-24 00:01:11 +01:00

fix InOrderService::poll_ready() nested service rediness check

This commit is contained in:
Nikolay Kim 2019-03-12 16:03:05 -07:00
parent 5e6eed905c
commit 21c289d7e4
4 changed files with 10 additions and 6 deletions

View File

@ -33,7 +33,7 @@ ssl = ["openssl", "tokio-openssl"]
rust-tls = ["rustls", "tokio-rustls", "webpki", "webpki-roots"]
[dependencies]
actix-rt = "0.2.0"
actix-rt = "0.2.1"
actix-service = "0.3.3"
actix-server-config = { path="../actix-server-config" }

View File

@ -10,6 +10,8 @@
* Fix `InFlightService::poll_ready()` nested service readiness check
* Fix `InOrderService::poll_ready()` nested service readiness check
## [0.3.3] - 2019-03-09

View File

@ -27,4 +27,4 @@ tokio-current-thread = "0.1.4"
log = "0.4"
[dev-dependencies]
actix-rt = "0.2"
actix-rt = "0.2.1"

View File

@ -140,9 +140,6 @@ where
// poll_ready could be called from different task
self.task.register();
// check nested service
self.service.poll_ready().map_err(InOrderError::Service)?;
// check acks
while !self.acks.is_empty() {
let rec = self.acks.front_mut().unwrap();
@ -156,8 +153,13 @@ where
}
}
// check nested service
if let Async::NotReady = self.service.poll_ready().map_err(InOrderError::Service)? {
Ok(Async::NotReady)
} else {
Ok(Async::Ready(()))
}
}
fn call(&mut self, request: S::Request) -> Self::Future {
let (tx1, rx1) = oneshot::channel();