2 Replies Latest reply on Feb 14, 2011 12:43 PM by Linnet S

    Quartz + WebLogic + JobStoreCMT difficulty retrieving jobs

    Linnet S Newbie

      I'm having difficulty setting up Quartz (1.6.5) on Weblogic 10.3 using JobStoreCMT.


      The application deploys fine...




      15:06:58,201 INFO [SchedulerSignalerImpl] Initialized Scheduler Signaller of type: class org.quartz.core.SchedulerSignalerImpl
      15:06:58,201 INFO [QuartzScheduler] Quartz Scheduler v.1.6.5 created.
      15:06:58,201 INFO [JobStoreCMT] Using db table-based data access locking (synchronization).
      15:06:59,544 INFO [JobStoreCMT] Removed 0 Volatile Trigger(s).
      15:06:59,544 INFO [JobStoreCMT] Removed 0 Volatile Job(s).
      15:06:59,591 INFO [JobStoreCMT] JobStoreCMT initialized.
      15:06:59,591 INFO [StdSchedulerFactory] Quartz scheduler 'SeamScheduler' initialized from an externally opened InputStream.
      15:06:59,591 INFO [StdSchedulerFactory] Quartz scheduler version: 1.6.5
      15:06:59,685 INFO [JobStoreCMT] Freed 0 triggers from 'acquired' / 'blocked' state.
      15:06:59,732 INFO [JobStoreCMT] Recovering 0 jobs that were in-progress at the time of the last shut-down.
      15:06:59,732 INFO [JobStoreCMT] Recovery complete.
      15:06:59,732 INFO [JobStoreCMT] Removed 0 'complete' triggers.
      15:06:59,732 INFO [JobStoreCMT] Removed 0 stale fired job entries.
      15:06:59,747 INFO [QuartzScheduler] Scheduler SeamScheduler_$_1 started.





      My properties are defined as follows:




      org.quartz.scheduler.instanceName = SeamScheduler
      org.quartz.scheduler.instanceId = 1
      org.quartz.scheduler.rmi.export = false
      org.quartz.scheduler.rmi.proxy = false
      org.quartz.scheduler.threadsInheritContextClassLoaderOfInitializer = true
      
      org.quartz.threadPool.class = org.quartz.simpl.SimpleThreadPool
      org.quartz.threadPool.threadCount = 3
      org.quartz.threadPool.threadPriority = 4
      
      org.quartz.scheduler.logger = schedLogger
      org.quartz.logger.schedLogger.class = org.quartz.impl.Log4jLogger
      
      org.quartz.jobStore.class = org.quartz.impl.jdbcjobstore.JobStoreCMT
      org.quartz.jobStore.driverDelegateClass = org.quartz.impl.jdbcjobstore.oracle.OracleDelegate
      org.quartz.jobStore.dataSource = QUARTZ
      org.quartz.jobStore.nonManagedTXDataSource = myDS
      org.quartz.jobStore.tablePrefix = QRTZ_
      org.quartz.jobStore.useProperties = false
      org.quartz.jobStore.misfireThreshold = 60000
      org.quartz.jobStore.dontSetAutoCommitFalse=true
      org.quartz.jobStore.selectWithLockSQL = SELECT * FROM {0}LOCKS WHERE LOCK_NAME = ?
      org.quartz.jobStore.isClustered = false
      org.quartz.jobStore.txIsolationLevelReadCommitted = true
      
      org.quartz.dataSource.QUARTZ.driver = oracle.jdbc.driver.OracleDriver
      org.quartz.dataSource.QUARTZ.URL = jdbc:oracle:thin:sa/sa@127.0.0.1:1521:xe
      org.quartz.dataSource.QUARTZ.user = sa
      org.quartz.dataSource.QUARTZ.password = sa
      org.quartz.dataSource.QUARTZ.maxConnections = 10
      
      #org.quartz.dataSource.QUARTZ.jndiURL = java:/email-managerDS
      org.quartz.dataSource.myDS.driver = oracle.jdbc.driver.OracleDriver
      org.quartz.dataSource.myDS.URL = jdbc:oracle:thin:sa/sa@127.0.0.1:1521:xe
      org.quartz.dataSource.myDS.user = sa
      org.quartz.dataSource.myDS.password = sa
      org.quartz.dataSource.myDS.maxConnections = 10





      And I can store a job in the database but when Quartz goes to retrieve the job I get the following error:




      2011-02-03 14:25:35,900 ERROR [org.quartz.impl.jdbcjobstore.JobStoreCMT] Error retrieving job, setting trigger state to ERROR.
      org.quartz.JobPersistenceException: Couldn't retrieve job because a required class was not found: org.jboss.seam.async.AsynchronousInvocation [See nested exception: java.lang.ClassNotFoundException: org.jboss.seam.async.AsynchronousInvocation]
      at org.quartz.impl.jdbcjobstore.JobStoreSupport.retrieveJob(JobStoreSupport.java:1392)
      at org.quartz.impl.jdbcjobstore.JobStoreSupport.triggerFired(JobStoreSupport.java:2879)
      at org.quartz.impl.jdbcjobstore.JobStoreSupport$38.execute(JobStoreSupport.java:2847)
      at org.quartz.impl.jdbcjobstore.JobStoreSupport.executeInNonManagedTXLock(JobStoreSupport.java:3760)
      at org.quartz.impl.jdbcjobstore.JobStoreSupport.triggerFired(JobStoreSupport.java:2841)
      at org.quartz.core.QuartzSchedulerThread.run(QuartzSchedulerThread.java:342)
      Caused by: java.lang.ClassNotFoundException: org.jboss.seam.async.AsynchronousInvocation
      at java.net.URLClassLoader$1.run(URLClassLoader.java:200)
      at java.security.AccessController.doPrivileged(Native Method)
      at java.net.URLClassLoader.findClass(URLClassLoader.java:188)
      at java.lang.ClassLoader.loadClass(ClassLoader.java:307)
      at sun.misc.Launcher$AppClassLoader.loadClass(Launcher.java:301)
      at java.lang.ClassLoader.loadClass(ClassLoader.java:252)
      at java.lang.ClassLoader.loadClassInternal(ClassLoader.java:320)
      at java.lang.Class.forName0(Native Method)
      at java.lang.Class.forName(Class.java:247)
      at java.io.ObjectInputStream.resolveClass(ObjectInputStream.java:604)
      at java.io.ObjectInputStream.readNonProxyDesc(ObjectInputStream.java:1575)
      at java.io.ObjectInputStream.readClassDesc(ObjectInputStream.java:1496)
      at java.io.ObjectInputStream.readOrdinaryObject(ObjectInputStream.java:1732)
      at java.io.ObjectInputStream.readObject0(ObjectInputStream.java:1329)
      at java.io.ObjectInputStream.readObject(ObjectInputStream.java:351)
      at java.util.HashMap.readObject(HashMap.java:1030)
      at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
      at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
      at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
      at java.lang.reflect.Method.invoke(Method.java:597)
      at java.io.ObjectStreamClass.invokeReadObject(ObjectStreamClass.java:974)
      at java.io.ObjectInputStream.readSerialData(ObjectInputStream.java:1849)
      at java.io.ObjectInputStream.readOrdinaryObject(ObjectInputStream.java:1753)
      at java.io.ObjectInputStream.readObject0(ObjectInputStream.java:1329)
      at java.io.ObjectInputStream.defaultReadFields(ObjectInputStream.java:1947)
      at java.io.ObjectInputStream.readSerialData(ObjectInputStream.java:1871)
      at java.io.ObjectInputStream.readOrdinaryObject(ObjectInputStream.java:1753)
      at java.io.ObjectInputStream.readObject0(ObjectInputStream.java:1329)
      at java.io.ObjectInputStream.readObject(ObjectInputStream.java:351)
      at org.quartz.impl.jdbcjobstore.oracle.OracleDelegate.getObjectFromBlob(OracleDelegate.java:161)
      at org.quartz.impl.jdbcjobstore.StdJDBCDelegate.selectJobDetail(StdJDBCDelegate.java:907)
      at org.quartz.impl.jdbcjobstore.JobStoreSupport.retrieveJob(JobStoreSupport.java:1380)
      ... 5 more





      I have both quartz-1.6.5.jar and jboss-seam.jar in the EAR directory.


      However I am on WebLogic so I had to define my jboss-seam jar as an ejb module in my application.xml




      <module>
              <ejb>jboss-seam.jar</ejb>
          </module>





      In components.xml the following defined:



      <async:quartz-dispatcher />




      I know that there is a jboss-seam-wls-compatible.jar but that does not contain the class that I need.