mirror of
https://github.com/fafhrd91/actix-net
synced 2025-02-20 08:50:32 +01:00
Fix max concurrent connections handling
This commit is contained in:
parent
640c39fdc8
commit
37d28304c9
@ -1,5 +1,12 @@
|
|||||||
# Changes
|
# Changes
|
||||||
|
|
||||||
|
## [0.1.3] - 2018-12-21
|
||||||
|
|
||||||
|
## Fixed
|
||||||
|
|
||||||
|
* Fix max concurrent connections handling
|
||||||
|
|
||||||
|
|
||||||
## [0.1.2] - 2018-12-12
|
## [0.1.2] - 2018-12-12
|
||||||
|
|
||||||
## Changed
|
## Changed
|
||||||
|
@ -1,6 +1,6 @@
|
|||||||
[package]
|
[package]
|
||||||
name = "actix-server"
|
name = "actix-server"
|
||||||
version = "0.1.2"
|
version = "0.1.3"
|
||||||
authors = ["Nikolay Kim <fafhrd91@gmail.com>"]
|
authors = ["Nikolay Kim <fafhrd91@gmail.com>"]
|
||||||
description = "Actix server - General purpose tcp server"
|
description = "Actix server - General purpose tcp server"
|
||||||
keywords = ["network", "framework", "async", "futures"]
|
keywords = ["network", "framework", "async", "futures"]
|
||||||
|
@ -83,9 +83,9 @@ where
|
|||||||
});
|
});
|
||||||
|
|
||||||
if let Ok(stream) = stream {
|
if let Ok(stream) = stream {
|
||||||
spawn(self.service.call(stream).map_err(|_| ()).map(move |val| {
|
spawn(self.service.call(stream).then(move |res| {
|
||||||
drop(guard);
|
drop(guard);
|
||||||
val
|
res.map_err(|_| ())
|
||||||
}));
|
}));
|
||||||
ok(())
|
ok(())
|
||||||
} else {
|
} else {
|
||||||
@ -122,9 +122,9 @@ where
|
|||||||
}
|
}
|
||||||
|
|
||||||
fn call(&mut self, (guard, req): (Option<CounterGuard>, ServerMessage)) -> Self::Future {
|
fn call(&mut self, (guard, req): (Option<CounterGuard>, ServerMessage)) -> Self::Future {
|
||||||
spawn(self.service.call(req).map_err(|_| ()).map(move |val| {
|
spawn(self.service.call(req).then(move |res| {
|
||||||
drop(guard);
|
drop(guard);
|
||||||
val
|
res.map_err(|_| ())
|
||||||
}));
|
}));
|
||||||
ok(())
|
ok(())
|
||||||
}
|
}
|
||||||
|
Loading…
x
Reference in New Issue
Block a user