mirror of
https://github.com/YGGverse/aquatic.git
synced 2026-04-03 03:05:31 +00:00
aquatic_udp: split cleaning interval for connections and torrents
This commit is contained in:
parent
5f10e5e7f4
commit
afe3e2465f
5 changed files with 20 additions and 13 deletions
|
|
@ -88,7 +88,9 @@ pub fn run_socket_worker(
|
|||
if iter_counter % 32 == 0 {
|
||||
let now = Instant::now();
|
||||
|
||||
if last_cleaning + Duration::from_secs(config.cleaning.interval) > now {
|
||||
if last_cleaning + Duration::from_secs(config.cleaning.connection_cleaning_interval)
|
||||
> now
|
||||
{
|
||||
connections.clean();
|
||||
|
||||
last_cleaning = now;
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue