Update seedleech params

In anticipation of more new trackers (6) and significantly more torrents
(2 million -> 20 million).

Required seedleech freshness now updated to guarantee very fresh counts
for popular torrents at the expense of torrents with 1-3 seeds.

I also again changed the sleep time for workfetcher with minseed 0: computing all torrents without a trackerdata entry is computionally expensive, impossible with 20 mil torrents.
pull/27/head
Urban Guacamole 4 years ago
parent 0b5b4ae88d
commit 446fdf4762

@ -2,4 +2,4 @@ trackers = ["udp://tracker.coppersurfer.tk:6969", "udp://tracker.leechers-paradi
waitTime = "500ms"
logInterval = "5m"
categories = { 0 = "1440h", 1 = "720h", 3 = "240h", 10 = "180h", 100 = "24h", 1000 = "10h", 2000 = "4h", 3000 = "2h"}
categories = { 0 = "2880h", 1 = "1440h", 3 = "720h", 10 = "96h", 60 = "48h", 100 = "24h", 500 = "8h", 1000 = "2h"}

@ -105,7 +105,7 @@ func runWorkFetcher(trackerRequests chan []string, tracker string, minseed int,
if minseed != 0 {
rows, err = db.Query("SELECT infohash FROM trackerdata WHERE tracker = $1 AND seeders > $2 AND scraped < $3 LIMIT 630", tracker, minseed, freshlimit)
} else {
time.Sleep(time.Duration(int64(rand.Intn(3000)) * int64(time.Second))) //sleep for random time between 0 mins and 50 mins
time.Sleep(time.Duration(int64(rand.Intn(12000)) * int64(time.Second))) //sleep for random time between 0 mins and 200 mins
rows, err = db.Query("SELECT infohash FROM torrent WHERE NOT EXISTS (SELECT from trackerdata WHERE infohash = torrent.infohash AND tracker = $1 AND scraped > $2) LIMIT 6300", tracker, freshlimit)
}
if err != nil {
@ -130,7 +130,7 @@ func runWorkFetcher(trackerRequests chan []string, tracker string, minseed int,
}
}
trackerRequests <- infohashes
time.Sleep(time.Minute)
time.Sleep(5 * time.Minute)
}
}
@ -192,7 +192,7 @@ func initDb() *sql.DB {
_, err = db.Exec(`DO $$
BEGIN
IF NOT EXISTS (SELECT 1 FROM pg_type WHERE typname = 'tracker') THEN
CREATE TYPE tracker AS ENUM ('udp://tracker.coppersurfer.tk:6969', 'udp://exodus.desync.com:6969', 'udp://tracker.pirateparty.gr:6969','udp://tracker.opentrackr.org:1337/announce','udp://tracker.internetwarriors.net:1337/announce','udp://tracker.cyberia.is:6969/announce','udp://9.rarbg.to:2920/announce');
CREATE TYPE tracker AS ENUM ('udp://tracker.coppersurfer.tk:6969', 'udp://tracker.leechers-paradise.org:6969/announce', 'udp://exodus.desync.com:6969', 'udp://tracker.pirateparty.gr:6969','udp://tracker.opentrackr.org:1337/announce','udp://tracker.internetwarriors.net:1337/announce','udp://tracker.cyberia.is:6969/announce','udp://9.rarbg.to:2920/announce');
END IF;
END$$`)
if err != nil {

Loading…
Cancel
Save