go-timer-wheel

时间:2021-05-31 23:49:51
【文件属性】:
文件名称:go-timer-wheel
文件大小:93KB
文件格式:ZIP
更新时间:2021-05-31 23:49:51
Go go-timer-wheel 基于时间轮的任务超时调度库 ========================= 安装方式 package main import ( "fmt" github.com/zhangwei1234/go-timer-wheel/timerWheel" ) func main() { wheel := timerWheel.NewTimerWheel()//初始化 wheel.Start()//启动 wheel.AddTask(&MyTask{}, 4 * time.Second) } type MyTask struct { } func(tk *MyTask) Expire() { fmt.Printf("-----------------> 执行 \n") } Developing You can run t
【文件预览】:
go-timer-wheel-master
----.project(380B)
----type.go(834B)
----guid.go(434B)
----scheduler_test.go(1KB)
----README.md(529B)
----docs()
--------wheel.png(93KB)
----time_wheel.go(3KB)

网友评论