title: What's Wrong with this Quartz Configuration?
body: <p>I have Quartz Scheduler running within WebLogic 12.1.3 and backed by a JobStoreCMT, but its behavior doesn't match the configuration (see below). What am I doing wrong?</p>
  
  <h2>Background</h2>
  
  <p>Quartz has jobs that are loaded from an XML file on startup and run periodically. Some of those jobs spawn one-time jobs. Also, there are one-time jobs that are manually triggered by users. The user-initiated jobs are done from EJBs that have container-managed transactions.</p>
  
  <h2>Questions</h2>
  
  <ol>
  <li>The transactions in the job classes are not active in the job's execute() method. I have to call begin/commit/rollback. Shouldn't that be taken care of since <em>wrapJobExecutionInUserTransaction</em> is set to true? That's what the documentation says.</li>
  <li>The documentation also says that when using <em>XMLSchedulingDataProcessorPlugin</em> with <em>JobStoreCMT</em>, <em>org.quartz.plugin.jobInitializer.wrapInUserTransaction</em> must be set to true. However, when I do that I get a duplicate transaction exception. What's going on?</li>
  <li>WebLogic takes forever to shut down whenever Quartz is enabled even though all of the jobs run quickly. From the logs it looks like WebLogic is waiting for the transactions to time out. Is something in the config contributing to this?</li>
  </ol>
  
  <h2>Configuration</h2>
  
  <pre><code>org.quartz.scheduler.skipUpdateCheck=true
  org.quartz.scheduler.instanceName=MyTaskScheduler
  org.quartz.scheduler.threadsInheritContextClassLoaderOfInitializer=true
  org.quartz.scheduler.instanceId=AUTO
  org.quartz.scheduler.wrapJobExecutionInUserTransaction=true
  org.quartz.scheduler.userTransactionURL=javax.transaction.UserTransaction
  org.quartz.scheduler.idleWaitTime=30000
  org.quartz.scheduler.dbFailureRetryInterval=15000
  org.quartz.scheduler.batchTriggerAcquisitionMaxCount=1
  org.quartz.scheduler.batchTriggerAcquisitionFireAheadTimeWindow=0
  org.quartz.scheduler.makeSchedulerThreadDaemon=false
  
  org.quartz.threadPool.class=org.quartz.simpl.SimpleThreadPool
  org.quartz.threadPool.threadCount=20
  org.quartz.threadPool.threadPriority=5
  org.quartz.threadPool.makeThreadsDaemons=false
  
  org.quartz.jobStore.class=org.quartz.impl.jdbcjobstore.JobStoreCMT
  org.quartz.jobStore.driverDelegateClass=org.quartz.impl.jdbcjobstore.oracle.weblogic.WebLogicOracleDelegate
  org.quartz.jobStore.dataSource=MyDataSource
  org.quartz.jobStore.nonManagedTXDataSource=MyDataSourceNonXA
  org.quartz.jobStore.tablePrefix=QRTZ_
  org.quartz.jobStore.useProperties=false
  org.quartz.jobStore.misfireThreshold=60000
  org.quartz.jobStore.isClustered=true
  org.quartz.jobStore.clusterCheckinInterval=15000
  org.quartz.jobStore.maxMisfiresToHandleAtATime=20
  org.quartz.jobStore.txIsolationLevelSerializable=false
  org.quartz.jobStore.txIsolationLevelReadCommitted=false 
  
  org.quartz.dataSource.MyDataSource.jndiURL=MyDataSource
  org.quartz.dataSource.MyDataSource.java.naming.factory.initial=weblogic.jndi.WLInitialContextFactory
  org.quartz.dataSource.MyDataSource.java.naming.provider.url=t3://localhost:7003
  
  org.quartz.dataSource.MyDataSourceNonXA.jndiURL=MyDataSourceNonXA
  org.quartz.dataSource.MyDataSourceNonXA.java.naming.factory.initial=weblogic.jndi.WLInitialContextFactory
  org.quartz.dataSource.MyDataSourceNonXA.java.naming.provider.url=t3://localhost:7003
  
  org.quartz.plugin.jobInitializer.class=org.quartz.plugins.xml.XMLSchedulingDataProcessorPlugin
  org.quartz.plugin.jobInitializer.fileNames=E:/tasks.xml
  org.quartz.plugin.jobInitializer.failOnFileNotFound=true
  org.quartz.plugin.jobInitializer.scanInterval=0
  org.quartz.plugin.jobInitializer.wrapInUserTransaction=false
  </code></pre>
  
  <p>Any help is appreciated.</p>