mirror of
https://github.com/YGGverse/aquatic.git
synced 2026-04-01 10:15:31 +00:00
Reduce ValidUntil size; reduce size of various ws structs
This commit is contained in:
parent
97fa699476
commit
fcf18c845f
21 changed files with 343 additions and 193 deletions
|
|
@ -6,6 +6,7 @@ use std::{collections::VecDeque, sync::Arc};
|
|||
|
||||
use aquatic_common::{
|
||||
privileges::PrivilegeDropper, rustls_config::create_rustls_config, PanicSentinelWatcher,
|
||||
ServerStartInstant,
|
||||
};
|
||||
use common::ChannelRequestSender;
|
||||
use dotenv::dotenv;
|
||||
|
|
@ -40,6 +41,8 @@ pub fn run(config: Config) -> anyhow::Result<()> {
|
|||
let (sentinel_watcher, sentinel) = PanicSentinelWatcher::create_with_sentinel();
|
||||
let priv_dropper = PrivilegeDropper::new(config.privileges.clone(), config.socket_workers);
|
||||
|
||||
let server_start_instant = ServerStartInstant::new();
|
||||
|
||||
let mut handles = Vec::new();
|
||||
|
||||
for _ in 0..config.socket_workers {
|
||||
|
|
@ -71,7 +74,14 @@ pub fn run(config: Config) -> anyhow::Result<()> {
|
|||
|
||||
let handle = ::std::thread::Builder::new()
|
||||
.name("request".into())
|
||||
.spawn(move || workers::swarm::run_swarm_worker(sentinel, config, request_receiver))?;
|
||||
.spawn(move || {
|
||||
workers::swarm::run_swarm_worker(
|
||||
sentinel,
|
||||
config,
|
||||
request_receiver,
|
||||
server_start_instant,
|
||||
)
|
||||
})?;
|
||||
|
||||
handles.push(handle);
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue