implement slow_torrent_ban argument option

This commit is contained in:
yggverse 2025-08-13 17:14:50 +03:00
parent 186c2b6cf1
commit 129d33f593
2 changed files with 16 additions and 4 deletions

View file

@ -98,7 +98,7 @@ pub struct Config {
#[arg(long, default_value_t = 60)]
pub add_torrent_timeout: u64,
/// Ban time in seconds on torrent add failure
/// Ban time in seconds on torrent add failure (`add_torrent_timeout` is reached)
#[arg(long, default_value_t = 3600)]
pub add_torrent_ban: u64,
@ -106,6 +106,10 @@ pub struct Config {
#[arg(long, default_value_t = 3600)]
pub resolve_torrent_ban: u64,
/// Ban time in seconds on torrent data download is longer than `add_torrent_timeout`
#[arg(long)]
pub slow_torrent_ban: Option<u64>,
/// Crawl loop delay in seconds
#[arg(long, default_value_t = 60)]
pub sleep: u64,