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

Function main

example/loadfromjson/task.go:23–43  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

21}
22
23func main() {
24 //step 1: init new task service
25 service = StartNewService()
26
27 service.
28 //step 2: register all task handler
29 RegisterHandler("Job_Config", Job_Config).
30 RegisterHandler("Loop_Config", Loop_Config).
31
32 //step 3: load config file
33 LoadFileConfig("c:/gotmp/task/task.json.conf", ConfigType_Json).
34
35 //step 4: start all task
36 StartAllTask()
37
38 fmt.Println(service.PrintAllTasks())
39
40 for {
41 time.Sleep(time.Hour)
42 }
43}

Callers

nothing calls this directly

Calls 5

StartNewServiceFunction · 0.85
StartAllTaskMethod · 0.80
LoadFileConfigMethod · 0.80
RegisterHandlerMethod · 0.80
PrintAllTasksMethod · 0.80

Tested by

no test coverage detected