[jboss-jira] [JBoss JIRA] Closed: (JBAS-30) txtimers created via Servlet init get duplicated.

Dimitris Andreadis (JIRA) jira-events at jboss.com
Wed Jan 10 03:12:32 EST 2007


     [ http://jira.jboss.com/jira/browse/JBAS-30?page=all ]

Dimitris Andreadis closed JBAS-30.
----------------------------------


> txtimers created via Servlet init get duplicated.
> -------------------------------------------------
>
>                 Key: JBAS-30
>                 URL: http://jira.jboss.com/jira/browse/JBAS-30
>             Project: JBoss Application Server
>          Issue Type: Bug
>      Security Level: Public(Everyone can see) 
>    Affects Versions: JBossAS-4.0.1 Final
>         Environment: jboss-4.0.1RC2
>            Reporter: Phil Cornelius
>         Assigned To: Scott M Stark
>             Fix For: JBossAS-4.0.1 Final
>
>
> I have a stateless SessionBean that is also a
> javax.ejb.TimedObject.
> I set the timer running by calling a 'schedule'
> business method
> public void schedule(int mins) {
>       TimerService timerService = mySessionCtx.getTimerService();
>       // Now and every mins minutes
>       timerService.createTimer(0L, 60000L * mins, "iPML export timer.");
> }
> This methods gets called from the init method of a
> Servlet.. everything works except that two timers get
> created.. the second about 20 seconds after the first..
> I have tracked it down to the following problem.. but
> am not sure how to solve it.
> 1. The timer gets created and a row is written into the
> localDB hypersonic database.
> 2. Once jboss is started (approx 20 seconds after the
> init method of my servlet was called) a notification is
> sent to org.jboss.ejb.txtimer.DatabasePersistencePolicy
> line 102
> where the method
>      restoreTimers();
> is called
> 3. This method reads the row in hsqldb and creates
> another duplicate txtimer
> The other thing that I noticed was that the instance
> variable 'instancePk' of the class
> org.jboss.ejb.txtimer.TimedObjectId never gets assigned
> any value.
> This bug is against jboss-4.0.1RC2
> Yours
> Phil

-- 
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: http://jira.jboss.com/jira/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira

        



More information about the jboss-jira mailing list