mirror of
https://github.com/fafhrd91/actix-net
synced 2025-06-28 16:50:37 +02:00
use actix deps instead of tokio
This commit is contained in:
@ -2,11 +2,11 @@ use std::sync::mpsc as sync_mpsc;
|
||||
use std::time::{Duration, Instant};
|
||||
use std::{io, thread};
|
||||
|
||||
use actix_rt::time::delay;
|
||||
use actix_rt::System;
|
||||
use futures::FutureExt;
|
||||
use log::{error, info};
|
||||
use slab::Slab;
|
||||
use tokio_timer::delay;
|
||||
|
||||
use crate::server::Server;
|
||||
use crate::socket::{SocketAddr, SocketListener, StdListener};
|
||||
|
@ -3,7 +3,7 @@ use std::task::{Context, Poll};
|
||||
use std::time::{Duration, Instant};
|
||||
use std::{io, mem, net};
|
||||
|
||||
use actix_rt::{spawn, Arbiter, System};
|
||||
use actix_rt::{spawn, time::delay, Arbiter, System};
|
||||
use futures::channel::mpsc::{unbounded, UnboundedReceiver};
|
||||
use futures::future::ready;
|
||||
use futures::stream::FuturesUnordered;
|
||||
@ -12,7 +12,6 @@ use log::{error, info};
|
||||
use net2::TcpBuilder;
|
||||
use num_cpus;
|
||||
use tokio_net::tcp::TcpStream;
|
||||
use tokio_timer::delay;
|
||||
|
||||
use crate::accept::{AcceptLoop, AcceptNotify, Command};
|
||||
use crate::config::{ConfiguredService, ServiceConfig};
|
||||
|
@ -1,6 +1,6 @@
|
||||
use std::{fmt, io, net};
|
||||
|
||||
use tokio_io::{AsyncRead, AsyncWrite};
|
||||
use actix_codec::{AsyncRead, AsyncWrite};
|
||||
use tokio_net::driver::Handle;
|
||||
use tokio_net::tcp::TcpStream;
|
||||
|
||||
|
@ -2,10 +2,10 @@ use std::convert::Infallible;
|
||||
use std::marker::PhantomData;
|
||||
use std::task::{Context, Poll};
|
||||
|
||||
use actix_codec::{AsyncRead, AsyncWrite};
|
||||
use actix_service::{Service, ServiceFactory};
|
||||
use futures::future::{self, FutureExt as _, LocalBoxFuture, TryFutureExt as _};
|
||||
use native_tls::Error;
|
||||
use tokio::io::{AsyncRead, AsyncWrite};
|
||||
use tokio_tls::{TlsAcceptor, TlsStream};
|
||||
|
||||
use crate::counter::Counter;
|
||||
|
@ -3,10 +3,10 @@ use std::marker::PhantomData;
|
||||
use std::pin::Pin;
|
||||
use std::task::{Context, Poll};
|
||||
|
||||
use actix_codec::{AsyncRead, AsyncWrite};
|
||||
use actix_service::{Service, ServiceFactory};
|
||||
use futures::future::{ok, FutureExt, LocalBoxFuture, Ready};
|
||||
use open_ssl::ssl::SslAcceptor;
|
||||
use tokio_io::{AsyncRead, AsyncWrite};
|
||||
use tokio_openssl::{HandshakeError, SslStream};
|
||||
|
||||
use crate::counter::{Counter, CounterGuard};
|
||||
|
@ -5,10 +5,10 @@ use std::pin::Pin;
|
||||
use std::sync::Arc;
|
||||
use std::task::{Context, Poll};
|
||||
|
||||
use actix_codec::{AsyncRead, AsyncWrite};
|
||||
use actix_service::{Service, ServiceFactory};
|
||||
use futures::future::{ok, Ready};
|
||||
use rust_tls::ServerConfig;
|
||||
use tokio_io::{AsyncRead, AsyncWrite};
|
||||
use tokio_rustls::{server::TlsStream, Accept, TlsAcceptor};
|
||||
|
||||
use crate::counter::{Counter, CounterGuard};
|
||||
|
@ -4,13 +4,13 @@ use std::sync::Arc;
|
||||
use std::task::{Context, Poll};
|
||||
use std::{mem, time};
|
||||
|
||||
use actix_rt::time::{delay, Delay};
|
||||
use actix_rt::{spawn, Arbiter};
|
||||
use futures::channel::mpsc::{UnboundedReceiver, UnboundedSender};
|
||||
use futures::channel::oneshot;
|
||||
use futures::future::{join_all, LocalBoxFuture, MapOk};
|
||||
use futures::{Future, FutureExt, Stream, TryFutureExt};
|
||||
use log::{error, info, trace};
|
||||
use tokio_timer::{delay, Delay};
|
||||
|
||||
use crate::accept::AcceptNotify;
|
||||
use crate::counter::Counter;
|
||||
|
Reference in New Issue
Block a user