mirror of
https://github.com/miniflux/v2.git
synced 2025-09-15 18:57:04 +00:00
Add logger
This commit is contained in:
parent
c6d9eb3614
commit
1d8193b892
56 changed files with 228 additions and 192 deletions
|
@ -5,9 +5,9 @@
|
|||
package scheduler
|
||||
|
||||
import (
|
||||
"log"
|
||||
"time"
|
||||
|
||||
"github.com/miniflux/miniflux/logger"
|
||||
"github.com/miniflux/miniflux/storage"
|
||||
)
|
||||
|
||||
|
@ -18,9 +18,9 @@ func NewScheduler(store *storage.Storage, workerPool *WorkerPool, frequency, bat
|
|||
for now := range c {
|
||||
jobs, err := store.NewBatch(batchSize)
|
||||
if err != nil {
|
||||
log.Println("[Scheduler]", err)
|
||||
logger.Error("[Scheduler] %v", err)
|
||||
} else {
|
||||
log.Printf("[Scheduler:%v] => Pushing %d jobs\n", now, len(jobs))
|
||||
logger.Debug("[Scheduler:%v] => Pushing %d jobs", now, len(jobs))
|
||||
workerPool.Push(jobs)
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue