package contracts import "git.fsdpf.net/go/req" type CronService interface { Start() error Stop() error Restart() error } type Cron interface { Controller // 任务处理 Run(req.User) error } type CronBase struct { Controller } func (CronBase) Run(req.User) error { return nil }