For my application i create jobs and schedule them with CronTriggers. Each job has only one trigger and both the job name and the trigger names are the same. No jobs share a trigger.
Now when i create a cron trigger like this "0/1 * * * * ?" which instructs the job to execute every second, it works just fine.
The problem rises when i first pause the job by calling :
scheduler.pauseJob(jobName, jobGroup);
and then resuming the job after let's say 50 seconds with :
scheduler.resumeJob(jobName, jobGroup);
What i see is that for these 50 seconds the job did not execute as requested. But the moment i resume the job i see 50 executions of the job at the same time!!!
I thought that this was due to the default setting for the misfire instruction but even after setting the trigger's misfire instruciton upon creation to this :
trigger.setMisfireInstruction(CronTrigger.MISFIRE_INSTRUCTION_DO_NOTHING);
The same thing happens. Can anyone suggest a way to fix this?