[jboss-jira] [JBoss JIRA] (AS7-2032) EJB Timer Service - cannot cancel configured calendar timer.
Marc Rosenthal (Issue Comment Edited) (JIRA)
jira-events at lists.jboss.org
Thu Dec 15 14:40:10 EST 2011
[ https://issues.jboss.org/browse/AS7-2032?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12651396#comment-12651396 ]
Marc Rosenthal edited comment on AS7-2032 at 12/15/11 2:38 PM:
---------------------------------------------------------------
I am having the same problem in 7.1.0.Beta1b: I call cancel() on the Timer, but it still runs. I am using a SingleActionTimer.
was (Author: mandrosen):
I am having the same problem in 7.1.0.Beta1b: I call cancel() on the Timer, but it still runs. Have you heard anything further on this?
> EJB Timer Service - cannot cancel configured calendar timer.
> ------------------------------------------------------------
>
> Key: AS7-2032
> URL: https://issues.jboss.org/browse/AS7-2032
> Project: Application Server 7
> Issue Type: Bug
> Components: EJB
> Affects Versions: 7.0.2.Final
> Environment: Windows 7
> jdk1.6.0_21
> Reporter: Andreas Wuttke
> Assignee: Stuart Douglas
> Fix For: 7.1.0.Final
>
>
> // Timer configuration
> private String payload = "This is the payload passed to the timer event";
> ScheduleExpression schedule = new ScheduleExpression().second(30).minute("*").hour("*").dayOfMonth("*").dayOfWeek("*").month("*").year("*");
> private Timer timer = timerService.createCalendarTimer(schedule, new TimerConfig(payload, true));
> ...
> timer.cancel(); // -> doesn't work!
> Collection<Timer> timers = timerService.getTimers();
> System.out.println("Timers configured: " + timers); // still reports the timer
> // Callback configuration
> @SuppressWarnings("unused")
> @Timeout
> private void configurationScheduledTimeout(final Timer t) {
> String info = (String) t.getInfo();
> System.out.println("configurationScheduledTimeout called at: " + new java.util.Date() + "info: " + info);
> }
> Cancel from within configurationScheduledTimeout also didn't work.
--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.jboss.org/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira
More information about the jboss-jira
mailing list