You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
but anywhere now using an alternative method like built-in timeout feature in gen_server or other functions in timer module that can cause timer to be accumulated under heavy load so maybe result in get system overloaded and cause timeout for gen_server:call such as #652.
Since the code (leo_mq and leo_watchdog) using alternative methods very frequently has been replaced with the timer:send_after and the other code also using alternative ones are less (>= timers:seconds(1)) called compared to leo_mq and leo_watchdog, there seems to be almost no code to be replaced.
Please drop the comment if you find any code to be replaced with timer:send_after at any other place.
I will close this issue if no one find such code.
Note:
leo_logger seems to have such code however now we are discussing on #729 to replace it with lager so it should not be deal breaker to close this issue.
yosukehara
changed the title
[all] Use timer:send_after for the periodic action in gen_server
[all] Use 'timer:send_after/3' for the periodic action in gen_server
Aug 10, 2017
not only
but anywhere now using an alternative method like built-in timeout feature in gen_server or other functions in timer module that can cause timer to be accumulated under heavy load so maybe result in get system overloaded and cause timeout for gen_server:call such as #652.
Reference: http://stackoverflow.com/questions/5883741/how-to-perform-actions-periodically-with-erlangs-gen-server
The text was updated successfully, but these errors were encountered: