Remove code relating to parallel execution from PeriodicalExecuter. #23
Remove code relating to parallel execution from PeriodicalExecuter. #23arbales wants to merge 2 commits intoprototypejs:masterfrom
Conversation
…nd other code relating to parallel execution.
There was a problem hiding this comment.
Didn't seem like this was performing any function that the previous test wasn't already doing, given that currentlyExecuting was removed.
|
(ping) |
|
Mind merging or closing? |
|
I'm guessing they've given up over here |
|
That's sad. Is there a a canonical fork? I don't use the library anymore, but I think lots do. Sent from my thumbs. On Mar 1, 2012, at 7:15 PM, Cecil Phillipreply@reply.github.com wrote:
|
|
Sorry — we dropped the ball on pull requests for a while. Can I ask why you think the code relating to parallel execution is unnecessary? I'm confused. It looks quite necessary to me if the point is to prevent an accumulation of callbacks in the case where your callback routinely takes longer than the interval. If your point is that JavaScript is single-threaded and thus nothing actually executes in "parallel," then I'll concede that it's a poor choice of words. Just want to make sure I'm not missing something here. |
|
HAHAHA DISREGARD THAT (now I see your point) Just shows how little this code has been touched over the years. Yeah, it doesn't prevent callback accumulation, and it's quite silly of us to have pretended that it did. So I have four options, as I see it:
I am leaning towards option #4 because we can't get rid of |
In PeriodicalExcuter, removed unnecessary
currentlyExecutingivar and other code relating to parallel execution.Since
#onTimerEventcontained no logic after this change, madesetIntervalcall (a bound)#executeand renamed#registerCallbackto#startso that the timer can be restarted at will. This behavior already existed in the previous (undocumented) function.Thanks!