1
0
mirror of https://github.com/fafhrd91/actix-net synced 2025-06-28 21:10:37 +02:00

use convert err on forward_ready! (#246)

This commit is contained in:
Rob Ede
2021-01-09 14:13:16 +00:00
committed by GitHub
parent a1982bdbad
commit f751cf5acb
15 changed files with 34 additions and 35 deletions

View File

@ -252,11 +252,6 @@ impl ServerBuilder {
Ok(self)
}
#[doc(hidden)]
pub fn start(self) -> Server {
self.run()
}
/// Starts processing incoming connections and return server controller.
pub fn run(mut self) -> Server {
if self.sockets.is_empty() {

View File

@ -12,7 +12,7 @@ use crate::{Server, ServerBuilder, ServiceFactory};
///
/// # Examples
///
/// ```rust
/// ```
/// use actix_service::fn_service;
/// use actix_server::TestServer;
///
@ -49,10 +49,7 @@ impl TestServer {
// run server in separate thread
thread::spawn(move || {
let sys = System::new("actix-test-server");
factory(Server::build())
.workers(1)
.disable_signals()
.start();
factory(Server::build()).workers(1).disable_signals().run();
tx.send(System::current()).unwrap();
sys.run()
@ -83,7 +80,7 @@ impl TestServer {
.unwrap()
.workers(1)
.disable_signals()
.start();
.run();
tx.send((System::current(), local_addr)).unwrap();
});
sys.run()