-
1. Re: ejbTimeout called when Timer.cancel is called
hanseno2 Apr 11, 2005 5:42 AM (in response to hanseno2)ejbTimeout was not called after Timer.cancel - it was called because i created a new Timer with a timeout that allready was expired. (Method is used to handle configuration changes)
I am still having problems cancelling timer - how can I securely cancel a Timer? (I can of course dotry {timer.cancel();} catch (Exception e) { /* Do nothing */ }
but this seems like a rather uglyu workaround... -
2. Re: ejbTimeout called when Timer.cancel is called
icruz Aug 3, 2007 7:50 AM (in response to hanseno2)Hello,
I have the same problem with JBoss 4.2.1GA. I have a @Service EJB, in start() method I create a EJB timer, and it works.
The first problem is when I shutdown jboss, in the stop() method of the Service EJB I call the method timer.cancel(), and it throws an exception with the message "timer was canceled", but the timer remains in the database (if I call stop() from the JMX console, it is cancelled correctly)
The second problem is when I restart jboss, in the start() method of my service EJB, the function timerService.getTimers() returns an empty collection (even the timer *is* in the database), and when I try to create the timer it fails with a "duplicate key" exception from MySQL driver
Thanks in advance,
Isaac -
3. Re: ejbTimeout called when Timer.cancel is called
axismundi Oct 19, 2007 7:09 AM (in response to hanseno2)"icruz" wrote:
Hello,
... and when I try to create the timer it fails with a "duplicate key" exception from MySQL driver
Thanks in advance,
Isaac
I wonder where in the JMX-console could you cancel the timer??
I was unable to find it.