本地定时任务

This commit is contained in:
Yun
2025-10-02 17:54:38 +08:00
parent 304d27e0ac
commit 2d6e77352f
4 changed files with 34 additions and 34 deletions
+5 -5
View File
@@ -6,11 +6,11 @@ import (
)
type timerStr struct {
Callback func(ctx context.Context, extendData interface{}) error // 需要回调的方法
CanRunning chan (struct{}) // 是否允许执行(only single)
TaskId string // 任务ID 全局唯一键(only cluster)
ExtendData interface{} // 附加参数
JobData *JobData // 任务时间数据
Callback func(ctx context.Context, extendData any) error // 需要回调的方法
CanRunning chan (struct{}) // 是否允许执行(only single)
TaskId string // 任务ID 全局唯一键
ExtendData any // 附加参数
JobData *JobData // 任务时间数据
}
type JobType string