Nonblocking disabled

This commit is contained in:
Ben Sarmiento
2024-01-28 18:36:57 +01:00
parent 0678af2bc2
commit 3cf3351210
2 changed files with 4 additions and 4 deletions

View File

@@ -51,7 +51,7 @@ func MainApp(configPath string) {
premium.MonitorPremiumStatus(rd, zurglog)
workerOptions := ants.Options{
Nonblocking: true,
// Nonblocking: true,
PanicHandler: func(i interface{}) {},
Logger: log.Named("worker"),
}
@@ -64,7 +64,7 @@ func MainApp(configPath string) {
defer workerPool.Release()
refreshOptions := ants.Options{
Nonblocking: true,
// Nonblocking: true,
PanicHandler: func(i interface{}) {},
Logger: log.Named("refreshworker"),
}
@@ -78,7 +78,7 @@ func MainApp(configPath string) {
defer refreshPool.Release()
repairOptions := ants.Options{
Nonblocking: true,
// Nonblocking: true,
PanicHandler: func(i interface{}) {},
Logger: log.Named("repairworker"),
}

View File

@@ -121,7 +121,7 @@ func (t *TorrentManager) refreshTorrents() []string {
// startRefreshJob periodically refreshes the torrents
func (t *TorrentManager) startRefreshJob() {
_ = t.workerPool.Submit(func() {
_ = t.refreshPool.Submit(func() {
t.log.Info("Starting periodic refresh job")
for {
<-time.After(time.Duration(t.Config.GetRefreshEverySecs()) * time.Second)