1
0
mirror of https://github.com/1Panel-dev/1Panel.git synced 2025-01-19 08:19:15 +08:00

fix: 调整监控数据采集间隔 (#607)

This commit is contained in:
ssongliu 2023-04-13 10:40:33 +08:00 committed by GitHub
parent 04a1cff37e
commit b646c5385d
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -15,7 +15,7 @@ import (
func Run() {
nyc, _ := time.LoadLocation("Asia/Shanghai")
Cron := cron.New(cron.WithLocation(nyc), cron.WithChain(cron.Recover(cron.DefaultLogger)), cron.WithChain(cron.DelayIfStillRunning(cron.DefaultLogger)))
_, err := Cron.AddJob("@every 1m", job.NewMonitorJob())
_, err := Cron.AddJob("@every 5m", job.NewMonitorJob())
if err != nil {
global.LOG.Errorf("can not add monitor corn job: %s", err.Error())
}