MCPcopy Create free account
hub / github.com/devfeel/dottask / Start

Method Start

crontask.go:88–100  ·  view source on GitHub ↗

Start start task

()

Source from the content-addressed store, hash-verified

86
87//Start start task
88func (task *CronTask) Start() {
89 if !task.IsRun {
90 return
91 }
92
93 task.mutex.Lock()
94 defer task.mutex.Unlock()
95
96 if task.State == TaskState_Init || task.State == TaskState_Stop {
97 task.State = TaskState_Run
98 startCronTask(task)
99 }
100}
101
102// RunOnce do task only once
103// no match Express or Interval

Callers 2

ResetMethod · 0.95

Calls 1

startCronTaskFunction · 0.85

Tested by

no test coverage detected