How-To: Storing a Job for Later Use

Storing a Job

   
// Define a durable job instance (durable jobs can exist without triggers)
JobDetail job1 = newJob(MyJobClass.class)
    .withIdentity("job1", "group1")
    .storeDurably()
    .build();

// Add the the job to the scheduler's store
sched.addJob(job, false);