Scheduler EJB 3.0


EJB programming & troubleshooting: Scheduler EJB 3.0

  1. Scheduler EJB 3.0 (2 messages)

    hi all, am currently working on a project using JSF, EJb3.0 and i was looking for a scheduler EJB that can run a query at a specific time i determine .. can any1 help?! thnx alot in advance.

    Threaded Messages (2)

  2. Re: Scheduler EJB 3.0[ Go to top ]

    You might want to look into Quartz.
  3. Scheduler EJB 3.0 using quartz[ Go to top ]

    well, i took ur advise and i took a look at Quartz; but when i tried the 1st example in the tutorial.. here's what i got: Exception in thread "main" java.lang.NoClassDefFoundError: org/apache/commons/logging/LogFactory at org.quartz.impl.StdSchedulerFactory.( at emak.model.client.UsersFacadeClientEmbed.main( the code i was trying to run is: public class UsersFacadeClientEmbed implements Job { public static void main(String[] args) { try { SchedulerFactory schedFact = new org.quartz.impl.StdSchedulerFactory(); Scheduler sched = schedFact.getScheduler(); sched.start(); JobDetail jobDetail = new JobDetail("myJob", null, UsersFacadeClientEmbed.class); Trigger trigger = TriggerUtils.makeSecondlyTrigge(); trigger.setStartTime(TriggerUtils.getEvenMinuteDate(new Date())); trigger.setName("myTrigger"); sched.scheduleJob(jobDetail, trigger); } catch (SchedulerException ex){ ex.printStackTrace(); } } public void execute(JobExecutionContext jobExecutionContext) { System.out.println("test successfull >>>>>>>>>"); } } can anyone plz help??!! thnx alot