[erlang-questions] bug in timer module in R14B02?

Fernando "Brujo" Benavides fernando.benavides@REDACTED
Tue Jun 21 15:00:22 CEST 2011


+1. We have the same issues here, and also moved to erlang:send_after.
We still use timer:send_interval but just for small intervals.

On 19/06/2011, at 23:02, Ryan Huffman wrote:

> I ran into a lot of problems with the timer module on R14B02 and eventually switched to using erlang:send_after.  This particular section in the erlang doc also convinced me to switch over to erlang:send_after and maintain my own timer: http://www.erlang.org/doc/efficiency_guide/commoncaveats.html#id58959
> 
> I was running on a 64-bit system (CentOS 5.5), so, as Dale mentioned, the problem may be fixed.
> 
> Ryan
> 
> On Sun, Jun 19, 2011 at 5:00 PM, Dale Harvey <dale@REDACTED> wrote:
> I believe there was an integer overflow bug on 64 bit systems that affect ordered ets tables (and therefore caused timers not to trigger) in R14B02
> 
> http://erlang.org/pipermail/erlang-bugs/2011-April/002294.html
> 
> That may be your problem?
> 
> 
> On 19 June 2011 03:43, Zsolt Keszthelyi <zsolt.erl@REDACTED> wrote:
> Dear All,
> 
> I ran into something in R14B02.
> It looks like if I start a timer with a long interval then all previously started timers stop.
> The timer server is still running and the timers are in the ETS table.
> No error returned. Nothing crashes.
> This was working on R13B03 and is not working on R14B02
> The long interval is exactly 2^31/1000 ms.
> Is it a bug or an intentional change?
> Maybe the timer module was never meant to be used with long intervals but shouldn't it give at least an error msg.?
> 
> Code:
> 
> %% works on R13B03
> %% doesn't work on R14B02
> 
> -module(timerbug).
> 
> -compile(export_all).
> 
> start()->
>    timer:apply_interval(1000, io, format, ["Hello!\n"]),
>    timer:sleep(5000),
>    timer:apply_interval(40*60*1000, io, format, ["No more hello.\n"]).
> 
> _______________________________________________
> erlang-questions mailing list
> erlang-questions@REDACTED
> http://erlang.org/mailman/listinfo/erlang-questions
> 
> 
> _______________________________________________
> erlang-questions mailing list
> erlang-questions@REDACTED
> http://erlang.org/mailman/listinfo/erlang-questions
> 
> 
> _______________________________________________
> erlang-questions mailing list
> erlang-questions@REDACTED
> http://erlang.org/mailman/listinfo/erlang-questions

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://erlang.org/pipermail/erlang-questions/attachments/20110621/839ce125/attachment.htm>


More information about the erlang-questions mailing list