1
0
mirror of https://github.com/fafhrd91/actix-web synced 2025-08-31 17:07:01 +02:00

rename Connections to more generic Counter and export it

This commit is contained in:
Nikolay Kim
2018-09-14 13:07:38 -07:00
parent 9888c1c5e6
commit 39c3902818
6 changed files with 93 additions and 88 deletions

View File

@@ -7,7 +7,7 @@ use tokio_openssl::{AcceptAsync, ConnectAsync, SslAcceptorExt, SslConnectorExt,
use super::MAX_CONN_COUNTER;
use connector::ConnectionInfo;
use server::{Connections, ConnectionsGuard};
use counter::{Counter, CounterGuard};
use service::{NewService, Service};
/// Support `SSL` connections via openssl package
@@ -59,7 +59,7 @@ impl<T: AsyncRead + AsyncWrite> NewService for OpensslAcceptor<T> {
pub struct OpensslAcceptorService<T> {
acceptor: SslAcceptor,
io: PhantomData<T>,
conns: Connections,
conns: Counter,
}
impl<T: AsyncRead + AsyncWrite> Service for OpensslAcceptorService<T> {
@@ -89,7 +89,7 @@ where
T: AsyncRead + AsyncWrite,
{
fut: AcceptAsync<T>,
_guard: ConnectionsGuard,
_guard: CounterGuard,
}
impl<T: AsyncRead + AsyncWrite> Future for OpensslAcceptorServiceFut<T> {