I have a problem while getting the instance for Quartz Scheduler, not at the first call but on the continuous calls.
This is my piece of code.
public void getClusteredSchedulerInstance() {
try {
cluteredScheduler = new StdSchedulerFactory("scheduler.properties").getScheduler();
if (!cluteredScheduler.isStarted()) {
cluteredScheduler.start();
}
} catch (SchedulerException e) {
logger.error("Error while starting clustered scheduler", e);
}
}
When i call the method for the first time it reads the property file and gives the instance, but fails to do so on further calls.
Can i know why this happens?
Note: scheduler.properties is located in the current working directory.
Error message
org.quartz.SchedulerException: Properties file: 'scheduler.properties' could not be read. [See nested exception: java.io.FileNotFoundException: scheduler.properties (The system cannot find the file specified)]