title: quartz cron trigger first fire time
body: <p>Is  there any way setting crontrigger to begin after a specific date .That is crontrigger going to fire after a specific date using its cron expression.I try using crontrigger starttime and firstfire time but not worked.I can do this with using another trigger but i think there should be another way.</p>
  
  <p>this is cron expression    </p>
  
  <pre><code>0  0/5  *  * * ? 
  </code></pre>
  
  <p>i.e. at minutes (5,10,15,...00) not at now+5 </p>
  
  <p>this is log  program writes</p>
  
  <p>Trigger should start at Fri May 27 21:03:31 EEST 2011   // i expect it run on this time</p>
  
  <pre><code>Job start at  Fri May 27 20:55:00 EEST 2011          //it ignore start time 
  Job start at  Fri May 27 21:00:00 EEST 2011
  Job start at  Fri May 27 21:05:00 EEST 2011
  </code></pre>
  
  <hr>
  
  <pre><code> public CronTrigger scheduleJob(RemoteJob job, String cronExpression,Date firstFireTime) throws SchedulerException, ParseException {
      JobDetail jobDetail = new JobDetail(job.getDescription(), job.getName(), job.getClass());
      CronTrigger crTrigger = new CronTrigger(
              "cronTrigger", job.getName(), cronExpression);       
      scheduler.scheduleJob(jobDetail, crTrigger);    
  
      try{
          Calendar  c=Calendar.getInstance();
          c.add(Calendar.MINUTE, 10);
          firstFireTime=c.getTime();
          FileWriter writer=new FileWriter("/opt/scheduler.cron",true);
          writer.write("Trigger should start at " +c.getTime().toString()+"\n\n");
          writer.close();
      }catch(Exception e){
  
      }
       crTrigger.setStartTime(firstFireTime);
      crTrigger.setMisfireInstruction(CronTrigger.MISFIRE_INSTRUCTION_DO_NOTHING);
  
      return crTrigger;
  
  }
  </code></pre>
  
  <p>this is job executed by trigger .</p>
  
  <pre><code>public class ExternalJob extends RemoteJob {
  
      private static final Logger _logger = Logger.getLogger(ExternalJob.class.getName());
      private static ExternalStorageProcessor processor = new ExternalStorageProcessor();
      private ExternalTask task;
      private static final String tempPath = "/opt/itaptemp/";
      private String name;
      private String description;
      private static final long MARK=1L;
  
      public ExternalJob(String name, String description) {
  
  
  
      public void execute(JobExecutionContext context) throws JobExecutionException {
  
  
           try{
              Calendar  c=Calendar.getInstance();          
  
              FileWriter writer=new FileWriter("/opt/scheduler.cron",true);
              writer.write("Job start at  " +c.getTime().toString()+"\n");
              writer.close();
          }catch(Exception e){
  
          }
  </code></pre>