mirror of
https://github.com/YGGverse/aquatic.git
synced 2026-04-02 02:35:31 +00:00
udp: rewrite socket worker to use SocketWorker struct
Also, stop checking token number all the time
This commit is contained in:
parent
9d37b3d285
commit
4587c267d6
4 changed files with 366 additions and 400 deletions
|
|
@ -21,6 +21,7 @@ use common::{
|
|||
};
|
||||
use config::Config;
|
||||
use workers::socket::validator::ConnectionValidator;
|
||||
use workers::socket::SocketWorker;
|
||||
|
||||
pub const APP_NAME: &str = "aquatic_udp: UDP BitTorrent tracker";
|
||||
pub const APP_VERSION: &str = env!("CARGO_PKG_VERSION");
|
||||
|
|
@ -121,11 +122,10 @@ pub fn run(config: Config) -> ::anyhow::Result<()> {
|
|||
WorkerIndex::SocketWorker(i),
|
||||
);
|
||||
|
||||
workers::socket::run_socket_worker(
|
||||
SocketWorker::run(
|
||||
sentinel,
|
||||
state,
|
||||
config,
|
||||
i,
|
||||
connection_validator,
|
||||
server_start_instant,
|
||||
request_sender,
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue