users@glassfish.java.net

Re: Why does my timer expunge?

From: Oliver B. Fischer <mailsink_at_swe-blog.net>
Date: Tue, 06 Aug 2013 13:55:23 +0200

No, not at all. I simply log the message. That's all. Strange...

Am 06.08.13 13:52, schrieb Lachezar Dobrev:
> Did the 'catch' code crash?
>
> 2013/8/6 Oliver B. Fischer <mailsink_at_swe-blog.net>:
>> Hi,
>>
>> I have a timeout callback method in a singleton which starts every minute:
>>
>> @Schedule(hour = "*", minute = "*", timezone = "UTC",
>> persistent = false, info = "InitialESSyncTimer")
>> protected void triggerFullUpdateAfterApplicationStart()
>> {
>> try {
>> runFullUpdate();
>> }
>> catch (RuntimeException e) {
>> ...
>> }
>> }
>>
>> This method is always expunged by GlassFish on every occurence of
>> RuntimeException? But why? I catch every exception. Actually the container
>> is only allowed to expunge a timer if the callback method throws an
>> exception.
>>
>> What did I miss?
>>
>> Best,
>>
>> Oliver