MCPcopy
hub / github.com/aceld/zinx / Run

Method Run

ztimer/timewheel.go:191–194  ·  view source on GitHub ↗

Run 非阻塞的方式让时间轮转起来

()

Source from the content-addressed store, hash-verified

189
190// Run 非阻塞的方式让时间轮转起来
191func (tw *TimeWheel) Run() {
192 go tw.run()
193 zlog.Ins().InfoF("timerwheel name = %s is running...", tw.name)
194}
195
196// GetTimerWithIn 获取定时器在一段时间间隔内的Timer
197func (tw *TimeWheel) GetTimerWithIn(duration time.Duration) map[uint32]*Timer {

Callers 2

TestTimerWheelFunction · 0.95
NewTimerSchedulerFunction · 0.95

Calls 3

runMethod · 0.95
InsFunction · 0.92
InfoFMethod · 0.65

Tested by 1

TestTimerWheelFunction · 0.76