Working on portmaster restructure

This commit is contained in:
Daniel
2018-11-29 18:44:31 +01:00
parent be8a1d1739
commit 3990790f17
26 changed files with 351 additions and 263 deletions

View File

@@ -9,20 +9,17 @@ import (
)
var (
deadLinksTimeout = 5 * time.Minute
thresholdDuration = 1 * time.Minute
cleanerTickDuration = 1 * time.Minute
deadLinksTimeout = 5 * time.Minute
thresholdDuration = 1 * time.Minute
)
func init() {
go cleaner()
}
func cleaner() {
time.Sleep(15 * time.Second)
for {
markDeadLinks()
purgeDeadFor(5 * time.Minute)
time.Sleep(15 * time.Second)
time.Sleep(cleanerTickDuration)
cleanLinks()
cleanConnections()
cleanProcesses()
}
}