title: Quartz scheduler : JOB Executed more than once
body: <p>I am using quartz scheduler to schedule my job. I have used CronTrigger. But the problem is there the trigger is getting fired more once. Here is my code to set up cron scheduler..</p>
  
  <pre><code>SchedulerFactory schFactory = new StdSchedulerFactory();
          Scheduler sched = null;
          CronTrigger cronTrigger = null;
          try {
              sched = schFactory.getScheduler();
              JobDetail jobDetail = new JobDetail("job1", "group1",SchedulerPBGC.class);
  
              String cronTimerStr = "* 16 15 * * ? *";
  
              LOG.warn("CRON TRIGGER FORMAT  FOR PROCESSING PB GC DATA:"+cronTimerStr);
  
              cronTrigger = new CronTrigger("SchedTrigger", "Group1", cronTimerStr);
  
  
              sched.scheduleJob(jobDetail, cronTrigger);          
              sched.start();
  
              LOG.warn("SCHEDULER REGISTERED FOR PROCESSING PB GC DATA :  TIME :"+cronTimerStr);          
  
          } catch (SchedulerException se) {
              LOG.error("SchedulerException Message::"+se.getLocalizedMessage());     
          }
  </code></pre>
  
  <p>Here my scheduler executes the job 10 times...Here you can see the logs ..</p>
  
  <pre><code>2012-06-20 15:16:50,001 DefaultQuartzScheduler_Worker-1 WARN  test.SchedulerPBGC - ----------PB GC SCHEDULER EXECUTION STARTED-----------------------
  2012-06-20 15:16:50,001 DefaultQuartzScheduler_Worker-1 WARN  test.SchedulerPBGC - The value of NO_OF_BEFORE_DAY_TO_RUN must be less then zero ..to start the scheduler
  2012-06-20 15:16:50,001 DefaultQuartzScheduler_Worker-1 WARN  test.SchedulerPBGC - ----------PB GC SCHEDULER EXECUTION COMPLETED-----------------------
  2012-06-20 15:16:51,001 DefaultQuartzScheduler_Worker-2 WARN  test.SchedulerPBGC - ----------PB GC SCHEDULER EXECUTION STARTED-----------------------
  2012-06-20 15:16:51,001 DefaultQuartzScheduler_Worker-2 WARN  test.SchedulerPBGC - The value of NO_OF_BEFORE_DAY_TO_RUN must be less then zero ..to start the scheduler
  2012-06-20 15:16:51,001 DefaultQuartzScheduler_Worker-2 WARN  test.SchedulerPBGC - ----------PB GC SCHEDULER EXECUTION COMPLETED-----------------------
  2012-06-20 15:16:52,001 DefaultQuartzScheduler_Worker-3 WARN  test.SchedulerPBGC - ----------PB GC SCHEDULER EXECUTION STARTED-----------------------
  2012-06-20 15:16:52,001 DefaultQuartzScheduler_Worker-3 WARN  test.SchedulerPBGC - The value of NO_OF_BEFORE_DAY_TO_RUN must be less then zero ..to start the scheduler
  2012-06-20 15:16:52,001 DefaultQuartzScheduler_Worker-3 WARN  test.SchedulerPBGC - ----------PB GC SCHEDULER EXECUTION COMPLETED-----------------------
  2012-06-20 15:16:53,001 DefaultQuartzScheduler_Worker-4 WARN  test.SchedulerPBGC - ----------PB GC SCHEDULER EXECUTION STARTED-----------------------
  2012-06-20 15:16:53,001 DefaultQuartzScheduler_Worker-4 WARN  test.SchedulerPBGC - The value of NO_OF_BEFORE_DAY_TO_RUN must be less then zero ..to start the scheduler
  2012-06-20 15:16:53,001 DefaultQuartzScheduler_Worker-4 WARN  test.SchedulerPBGC - ----------PB GC SCHEDULER EXECUTION COMPLETED-----------------------
  2012-06-20 15:16:54,001 DefaultQuartzScheduler_Worker-5 WARN  test.SchedulerPBGC - ----------PB GC SCHEDULER EXECUTION STARTED-----------------------
  2012-06-20 15:16:54,001 DefaultQuartzScheduler_Worker-5 WARN  test.SchedulerPBGC - The value of NO_OF_BEFORE_DAY_TO_RUN must be less then zero ..to start the scheduler
  2012-06-20 15:16:54,001 DefaultQuartzScheduler_Worker-5 WARN  test.SchedulerPBGC - ----------PB GC SCHEDULER EXECUTION COMPLETED-----------------------
  2012-06-20 15:16:55,001 DefaultQuartzScheduler_Worker-6 WARN  test.SchedulerPBGC - ----------PB GC SCHEDULER EXECUTION STARTED-----------------------
  2012-06-20 15:16:55,001 DefaultQuartzScheduler_Worker-6 WARN  test.SchedulerPBGC - The value of NO_OF_BEFORE_DAY_TO_RUN must be less then zero ..to start the scheduler
  2012-06-20 15:16:55,001 DefaultQuartzScheduler_Worker-6 WARN  test.SchedulerPBGC - ----------PB GC SCHEDULER EXECUTION COMPLETED-----------------------
  2012-06-20 15:16:56,001 DefaultQuartzScheduler_Worker-7 WARN  test.SchedulerPBGC - ----------PB GC SCHEDULER EXECUTION STARTED-----------------------
  2012-06-20 15:16:56,001 DefaultQuartzScheduler_Worker-7 WARN  test.SchedulerPBGC - The value of NO_OF_BEFORE_DAY_TO_RUN must be less then zero ..to start the scheduler
  2012-06-20 15:16:56,001 DefaultQuartzScheduler_Worker-7 WARN  test.SchedulerPBGC - ----------PB GC SCHEDULER EXECUTION COMPLETED-----------------------
  2012-06-20 15:16:57,001 DefaultQuartzScheduler_Worker-8 WARN  test.SchedulerPBGC - ----------PB GC SCHEDULER EXECUTION STARTED-----------------------
  2012-06-20 15:16:57,001 DefaultQuartzScheduler_Worker-8 WARN  test.SchedulerPBGC - The value of NO_OF_BEFORE_DAY_TO_RUN must be less then zero ..to start the scheduler
  2012-06-20 15:16:57,001 DefaultQuartzScheduler_Worker-8 WARN  test.SchedulerPBGC - ----------PB GC SCHEDULER EXECUTION COMPLETED-----------------------
  2012-06-20 15:16:58,001 DefaultQuartzScheduler_Worker-9 WARN  test.SchedulerPBGC - ----------PB GC SCHEDULER EXECUTION STARTED-----------------------
  2012-06-20 15:16:58,001 DefaultQuartzScheduler_Worker-9 WARN  test.SchedulerPBGC - The value of NO_OF_BEFORE_DAY_TO_RUN must be less then zero ..to start the scheduler
  2012-06-20 15:16:58,001 DefaultQuartzScheduler_Worker-9 WARN  test.SchedulerPBGC - ----------PB GC SCHEDULER EXECUTION COMPLETED-----------------------
  2012-06-20 15:16:59,001 DefaultQuartzScheduler_Worker-10 WARN  test.SchedulerPBGC - ----------PB GC SCHEDULER EXECUTION STARTED-----------------------
  2012-06-20 15:16:59,001 DefaultQuartzScheduler_Worker-10 WARN  test.SchedulerPBGC - The value of NO_OF_BEFORE_DAY_TO_RUN must be less then zero ..to start the scheduler
  2012-06-20 15:16:59,001 DefaultQuartzScheduler_Worker-10 WARN  test.SchedulerPBGC - ----------PB GC SCHEDULER EXECUTION COMPLETED--------------------
  </code></pre>
  
  <p>How can i set the CronTimer iterator to 1 ? OR How can I stop the scheduler to executing the job more than once.</p>
  
  <p>Any suggestion ?
  Thanks,
  Gunjan Shah.</p>