Package org.quartz

Examples of org.quartz.Scheduler.deleteJob()


        JobSpec spec = null;

        try {
            spec = (JobSpec) activationSpec;
            s.deleteJob(spec.jobKey());

        } catch (SchedulerException e) {
            throw new IllegalStateException("Failed to delete job", e);
        } finally {
            if (null != spec) {
View Full Code Here


            final String jobIdentity = scheduledJobDetail.getJobKey();
            final JobKey jobKey = constructJobKey(jobIdentity);
            final String schedulername = getSchedulerName(scheduledJobDetail);
            final Scheduler scheduler = this.schedulers.get(schedulername);
            if (scheduler != null) {
                scheduler.deleteJob(jobKey);
            }
            scheduleJob(scheduledJobDetail);
            this.schedularWritePlatformService.saveOrUpdate(scheduledJobDetail);
        } catch (final Throwable throwable) {
            final String stackTrace = getStackTraceAsString(throwable);
View Full Code Here

        }
      } else {
            Logger.info(DotInitScheduler.class, "Deliver Campaign Cron Thread schedule disabled on this server");
            Logger.info(DotInitScheduler.class, "Deleting DeliverCampaignJob Job");
        if ((job = sched.getJobDetail("DeliverCampaignJob", "dotcms_jobs")) != null) {
          sched.deleteJob("DeliverCampaignJob", "dotcms_jobs");
        }
      }

      if(Config.getBooleanProperty("ENABLE_UPDATE_RATINGS_THREAD")) {
        try {
View Full Code Here

            if ((job = sched.getJobDetail("UpdateRatingJob", "dotcms_jobs")) == null) {
              job = new JobDetail("UpdateRatingJob", "dotcms_jobs", UpdateRatingThread.class);
              isNew = true;
            }
          } catch (SchedulerException se) {
            sched.deleteJob("UpdateRatingJob", "dotcms_jobs");
            job = new JobDetail("UpdateRatingJob", "dotcms_jobs", UpdateRatingThread.class);
            isNew = true;
          }
          calendar = GregorianCalendar.getInstance();
          calendar.add(Calendar.SECOND, Config.getIntProperty("UPDATE_RATINGS_THREAD_INIT_DELAY"));
View Full Code Here

        }
      } else {
            Logger.info(DotInitScheduler.class, "Update Rating Cron Thread schedule disabled on this server");
            Logger.info(DotInitScheduler.class, "Deleting UpdateRatingJob Job");
        if ((job = sched.getJobDetail("UpdateRatingJob", "dotcms_jobs")) != null) {
          sched.deleteJob("UpdateRatingJob", "dotcms_jobs");
        }
      }

      if(Config.getBooleanProperty("ENABLE_CONTENT_REVIEW_THREAD")) {
        try {
View Full Code Here

            if ((job = sched.getJobDetail("ContentReviewJob", "dotcms_jobs")) == null) {
              job = new JobDetail("ContentReviewJob", "dotcms_jobs", ContentReviewThread.class);
              isNew = true;
            }
          } catch (SchedulerException se) {
            sched.deleteJob("ContentReviewJob", "dotcms_jobs");
            job = new JobDetail("ContentReviewJob", "dotcms_jobs", ContentReviewThread.class);
            isNew = true;
          }
          calendar = GregorianCalendar.getInstance();
          calendar.add(Calendar.SECOND, Config.getIntProperty("EXEC_INIT_DELAY"));
View Full Code Here

        }
      } else {
            Logger.info(DotInitScheduler.class, "Content Review Cron Thread schedule disabled on this server");
            Logger.info(DotInitScheduler.class, "Deleting ContentReviewJob Job");
        if ((job = sched.getJobDetail("ContentReviewJob", "dotcms_jobs")) != null) {
          sched.deleteJob("ContentReviewJob", "dotcms_jobs");
        }
      }


          try {
View Full Code Here

        }
      } else {
            Logger.info(DotInitScheduler.class, "Automatic Content Reindexation Cron Thread schedule disabled on this server");
            Logger.info(DotInitScheduler.class, "Deleting ContentReindexerJob Job");
        if ((job = sched.getJobDetail("ContentReindexerJob", "dotcms_jobs")) != null) {
          sched.deleteJob("ContentReindexerJob", "dotcms_jobs");
        }
      }

      //Bounces popper task
      if(Config.getBooleanProperty("ENABLE_POP_BOUNCES_THREAD")) {
View Full Code Here

            if ((job = sched.getJobDetail("PopBouncedMailJob", "dotcms_jobs")) == null) {
              job = new JobDetail("PopBouncedMailJob", "dotcms_jobs", PopBouncedMailThread.class);
              isNew = true;
            }
          } catch (SchedulerException se) {
            sched.deleteJob("PopBouncedMailJob", "dotcms_jobs");
            job = new JobDetail("PopBouncedMailJob", "dotcms_jobs", PopBouncedMailThread.class);
            isNew = true;
          }
          calendar = GregorianCalendar.getInstance();
          calendar.add(Calendar.SECOND, Config.getIntProperty("EXEC_POP_BOUNCES_INIT_DELAY"));
View Full Code Here

        }
      } else {
            Logger.info(DotInitScheduler.class, "Automatic Bounces Retrieval Cron Thread schedule disabled on this server");
            Logger.info(DotInitScheduler.class, "Deleting PopBouncedMailJob Job");
            if ((job = sched.getJobDetail("PopBouncedMailJob", "dotcms_jobs")) != null) {
          sched.deleteJob("PopBouncedMailJob", "dotcms_jobs");
        }
      }

      if(Config.getBooleanProperty("ENABLE_USERS_TO_DELETE_THREAD")) {
        try {
View Full Code Here

TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.