定时任务部分bug
This commit is contained in:
parent
ae38db28f7
commit
61b58ec546
13
main.go
13
main.go
|
|
@ -235,11 +235,12 @@ func ReadConfigToSetSystem() {
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
//存入redis
|
//存入redis
|
||||||
data, err := json.Marshal(cron_infos)
|
json_data, err := json.Marshal(cron_infos)
|
||||||
if err != nil {
|
if err != nil {
|
||||||
fmt.Println("Error encoding config")
|
fmt.Println("ReadConfigToSetSystem Error encoding config,value is :", cron_infos)
|
||||||
|
} else {
|
||||||
|
worker.SetRedis(key, string(json_data))
|
||||||
}
|
}
|
||||||
worker.SetRedis(key, string(data))
|
|
||||||
}
|
}
|
||||||
|
|
||||||
func RunGeneralCron() {
|
func RunGeneralCron() {
|
||||||
|
|
@ -267,11 +268,13 @@ func RunGeneralCron() {
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
//存入redis
|
//存入redis
|
||||||
data, err := json.Marshal(cron_infos)
|
json_data, err := json.Marshal(cron_infos)
|
||||||
if err != nil {
|
if err != nil {
|
||||||
fmt.Println("RunGeneralCron Error encoding config,value is :", cron_infos)
|
fmt.Println("RunGeneralCron Error encoding config,value is :", cron_infos)
|
||||||
|
} else {
|
||||||
|
worker.SetRedis(key, string(json_data))
|
||||||
}
|
}
|
||||||
worker.SetRedis(key, string(data))
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue