Package org.quartz

Examples of org.quartz.SchedulerConfigException


/*     */   {
/*     */     try
/*     */     {
/*  80 */       this.ctxt = new InitialContext();
/*     */     } catch (Exception e) {
/*  82 */       throw new SchedulerConfigException("JTAJobRunShellFactory initialization failed.", e);
/*     */     }
/*     */
/*  85 */     setUserTxLocation(userTxURL);
/*     */   }
View Full Code Here


/*     */   }
/*     */
/*     */   public void initialize() throws SchedulerConfigException
/*     */   {
/* 224 */     if (this.count <= 0) {
/* 225 */       throw new SchedulerConfigException("Thread count must be > 0");
/*     */     }
/* 227 */     if ((this.prio <= 0) || (this.prio > 9)) {
/* 228 */       throw new SchedulerConfigException("Thread priority must be > 0 and <= 9");
/*     */     }
/*     */
/* 231 */     if (isThreadsInheritGroupOfInitializingThread()) {
/* 232 */       this.threadGroup = Thread.currentThread().getThreadGroup();
/*     */     }
View Full Code Here

/*     */       {
/* 114 */         rebind();
/*     */       } catch (NamingException ne) {
/* 116 */         this.log.error(captureStackTrace(ne));
/*     */
/* 118 */         throw new SchedulerConfigException("Failed to rebind Scheduler - ", ne);
/*     */       }
/*     */     }
/*     */   }
View Full Code Here

/* 204 */         this.schedulerFactory.initialize(this.propertiesFile);
/*     */     }
/*     */     catch (Exception e) {
/* 207 */       this.log.error(captureStackTrace(e));
/*     */
/* 209 */       throw new SchedulerConfigException("Failed to initialize Scheduler - ", e);
/*     */     }
/*     */
/* 213 */     this.log.info("QuartzService(" + this.jndiName + ") created.");
/*     */   }
View Full Code Here

/*     */     {
/* 228 */       rebind();
/*     */     } catch (NamingException ne) {
/* 230 */       this.log.error(captureStackTrace(ne));
/*     */
/* 232 */       throw new SchedulerConfigException("Failed to rebind Scheduler - ", ne);
/*     */     }
/*     */
/*     */     try
/*     */     {
/* 237 */       Scheduler scheduler = this.schedulerFactory.getScheduler();
/*     */
/* 239 */       scheduler.start();
/*     */     } catch (Exception e) {
/* 241 */       this.log.error(captureStackTrace(e));
/*     */
/* 243 */       throw new SchedulerConfigException("Failed to start Scheduler - ", e);
/*     */     }
/*     */
/* 247 */     this.log.info("QuartzService(" + this.jndiName + ") started.");
/*     */   }
View Full Code Here

/*     */
/* 256 */       scheduler.shutdown();
/*     */     } catch (Exception e) {
/* 258 */       this.log.error(captureStackTrace(e));
/*     */
/* 260 */       throw new SchedulerConfigException("Failed to shutdown Scheduler - ");
/*     */     }
/*     */
/* 264 */     unbind(this.jndiName);
/*     */
/* 266 */     this.log.info("QuartzService(" + this.jndiName + ") stopped.");
View Full Code Here

/*  544 */     ClassLoadHelper loadHelper = null;
/*      */     try {
/*  546 */       loadHelper = (ClassLoadHelper)loadClass(classLoadHelperClass).newInstance();
/*      */     }
/*      */     catch (Exception e) {
/*  549 */       throw new SchedulerConfigException("Unable to instantiate class load helper class: " + e.getMessage(), e);
/*      */     }
/*      */
/*  553 */     loadHelper.initialize();
/*      */
/*  555 */     JobFactory jobFactory = null;
/*  556 */     if (jobFactoryClass != null) {
/*      */       try {
/*  558 */         jobFactory = (JobFactory)loadHelper.loadClass(jobFactoryClass).newInstance();
/*      */       }
/*      */       catch (Exception e) {
/*  561 */         throw new SchedulerConfigException("Unable to instantiate JobFactory class: " + e.getMessage(), e);
/*      */       }
/*      */
/*  566 */       tProps = this.cfg.getPropertyGroup("org.quartz.scheduler.jobFactory", true);
/*      */       try {
/*  568 */         setBeanProps(jobFactory, tProps);
/*      */       } catch (Exception e) {
/*  570 */         this.initException = new SchedulerException("JobFactory class '" + jobFactoryClass + "' props could not be configured.", e);
/*      */
/*  572 */         this.initException.setErrorCode(50);
/*      */
/*  574 */         throw this.initException;
/*      */       }
/*      */     }
/*      */
/*  578 */     InstanceIdGenerator instanceIdGenerator = null;
/*  579 */     if (instanceIdGeneratorClass != null) {
/*      */       try {
/*  581 */         instanceIdGenerator = (InstanceIdGenerator)loadHelper.loadClass(instanceIdGeneratorClass).newInstance();
/*      */       }
/*      */       catch (Exception e) {
/*  584 */         throw new SchedulerConfigException("Unable to instantiate InstanceIdGenerator class: " + e.getMessage(), e);
/*      */       }
/*      */
/*      */     }
/*      */
/*  593 */     String tpClass = this.cfg.getStringProperty("org.quartz.threadPool.class", null);
View Full Code Here

/*      */         else
/* 1087 */           throw new NoSuchMethodException("No primitive-type setter for property '" + name + "'");
/*      */       }
/*      */       catch (NumberFormatException nfe)
/*      */       {
/* 1091 */         throw new SchedulerConfigException("Could not parse property '" + name + "' into correct data type: " + nfe.toString());
/*      */       }
/*      */     }
/*      */   }
View Full Code Here

/*      */
/*      */   public void initialize(ClassLoadHelper loadHelper, SchedulerSignaler signaler)
/*      */     throws SchedulerConfigException
/*      */   {
/*  138 */     if (this.nonManagedTxDsName == null) {
/*  139 */       throw new SchedulerConfigException("Non-ManagedTX DataSource name not set!");
/*      */     }
/*      */
/*  142 */     setUseDBLocks(true);
/*      */
/*  144 */     super.initialize(loadHelper, signaler);
View Full Code Here

/*      */   }
/*      */
/*      */   public void initialize(ClassLoadHelper loadHelper, SchedulerSignaler signaler)
/*      */     throws SchedulerConfigException
/*      */   {
/*  470 */     if (this.dsName == null) throw new SchedulerConfigException("DataSource name not set.");
/*      */
/*  473 */     this.classLoadHelper = loadHelper;
/*  474 */     this.signaler = signaler;
/*      */
/*  476 */     if ((!getUseDBLocks()) && (!isClustered())) {
/*  477 */       getLog().info("Using thread monitor-based data access locking (synchronization).");
/*      */
/*  480 */       this.lockHandler = new SimpleSemaphore();
/*      */     } else {
/*  482 */       getLog().info("Using db table-based data access locking (synchronization).");
/*      */
/*  485 */       this.lockHandler = new StdRowLockSemaphore(getTablePrefix(), getSelectWithLockSQL());
/*      */     }
/*      */
/*  489 */     if (!isClustered())
/*      */       try {
/*  491 */         cleanVolatileTriggerAndJobs();
/*      */       } catch (SchedulerException se) {
/*  493 */         throw new SchedulerConfigException("Failure occured during job recovery.", se);
/*      */       }
/*      */   }
View Full Code Here

TOP

Related Classes of org.quartz.SchedulerConfigException

Copyright © 2018 www.massapicom. 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.