ferry/pkg/task/server.go
2020-07-15 01:40:56 +08:00

20 lines
296 B
Go
Raw Blame History

This file contains ambiguous Unicode characters

This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

package task
/*
@Author : lanyulei
*/
import (
"ferry/pkg/logger"
"ferry/pkg/task/worker"
)
func Start() {
// 启动异步任务框架
taskWorker := worker.NewAsyncTaskWorker(0)
err := taskWorker.Launch()
if err != nil {
logger.Errorf("启动machinery失败%v", err.Error())
}
}