18 Commits
Author SHA1 Message Date
xtaci 381f54c9f3 fix time comparsion on edge 2019-04-15 13:36:56 +08:00
xtaci 0be661ec07 reuse time.Timer object instead of creating repeatedly 2019-04-13 20:41:36 +08:00
xtaci af45077937 remove the threadlock 2018-12-28 20:42:53 +08:00
xtaci 1b01745940 pin updater to thread for better localiaty while sending 2018-12-24 19:57:55 +08:00
xtaci 5930020fc4 make the updater timing more accurate 2018-09-24 23:12:53 +08:00
Jin Qing 55c8a65090 use heap.Fix() instead of Pop() and Push()
From container/heap's doc:
Changing the value of the element at index i and then calling Fix is equivalent to, but less expensive than, calling Remove(h, i) followed by a Push of the new value.
2018-02-03 15:14:51 +08:00
xtaci 8a28b6fce2 add some comments & remove an unnecessary pre-condition 2017-06-03 19:14:50 +08:00
xtaci 8ed1e5b9e6 add a precondition before heap operations 2017-05-26 12:23:02 +08:00
xtaci 7f81f739c3 fix race 2017-05-25 16:46:07 +08:00
xtaci 9154723900 eliminate map in updater 2017-05-25 16:38:26 +08:00
xtaci 0423ef7410 user time.After for 0 cpu usage when idle 2017-03-25 22:46:36 +08:00
xtaci 42146c8c5f optimize updater, try not to allocate timer 2017-03-10 18:03:23 +08:00
xtaci 947067cce2 recycle faster in updater 2017-03-09 10:54:40 +08:00
xtaci c7796b7b86 add verbose comments 2017-03-08 10:37:15 +08:00
xtaci d8a3b1e4db delete goroutines in addSession & removeSession in updater 2017-02-28 21:56:51 +08:00
xtaci dafb7e7294 update tests 2017-02-28 21:16:06 +08:00
xtaci fe15067e9a rename func 2017-02-28 14:49:51 +08:00
xtaci 50ae95c410 add a global updater for scheduling efficency 2017-02-28 14:27:19 +08:00