RussellLuo / timingwheel

Golang implementation of Hierarchical Timing Wheels.
MIT License
660 stars 125 forks source link

What is this chan used for? #16

Closed alanxone closed 5 years ago

alanxone commented 5 years ago

Hi there,

I'm quite confused about this line, https://github.com/RussellLuo/timingwheel/blob/f534fd34a76229c9db53193e394bf7e58982236b/delayqueue/delayqueue.go#L177. After receiving the data from channel, it does nothing right?

But per your comment stated, it should send the expired element to wheel. Can you please explain the usage?

Thank you!

alanxone commented 5 years ago

I took some time and read your code carefully, now the problem is solved!

RussellLuo commented 4 years ago

The comments have been updated, see here for details.

@andrewtw Thanks for your attention, any more advice is welcome!