0 0

spring quartz 使用oracle作为持久化出现异常。10

使用sql server的时候一切都是正常的,但是更换成oracle数据库就报告异常:
ERROR -- ClusterManager: Error managing cluster: Failure updating scheduler state when checking-in: ORA-00904: "RECOVERER": 标识符无效

org.quartz.JobPersistenceException: Failure updating scheduler state when checking-in: ORA-00904: "RECOVERER": 标识符无效
[See nested exception: java.sql.SQLException: ORA-00904: "RECOVERER": 标识符无效
]
at org.quartz.impl.jdbcjobstore.JobStoreSupport.clusterCheckIn(JobStoreSupport.java:2130)
at org.quartz.impl.jdbcjobstore.JobStoreCMT.doCheckin(JobStoreCMT.java:1387)
at org.quartz.impl.jdbcjobstore.JobStoreSupport$ClusterManager.manage(JobStoreSupport.java:2378)
at org.quartz.impl.jdbcjobstore.JobStoreSupport$ClusterManager.initialize(JobStoreSupport.java:2365)
at org.quartz.impl.jdbcjobstore.JobStoreSupport.schedulerStarted(JobStoreSupport.java:506)
at org.quartz.core.QuartzScheduler.start(QuartzScheduler.java:396)
at org.quartz.impl.StdScheduler.start(StdScheduler.java:147)

我的quartz.properties配置如下:

org.quartz.jobStore.class = org.quartz.impl.jdbcjobstore.JobStoreCMT
org.quartz.jobStore.driverDelegateClass = org.quartz.impl.jdbcjobstore.oracle.OracleDelegate
org.quartz.jobStore.tablePrefix = QRTZ_
org.quartz.jobStore.misfireThreshold = 60000
org.quartz.jobStore.maxMisfiresToHandleAtATime = 20
org.quartz.jobStore.selectWithLockSQL = SELECT * FROM {0}LOCKS WHERE LOCK_NAME = ?

##===========================================================
## Configure Datasources
##===========================================================
#
#org.quartz.dataSource.myDS.driver = com.microsoft.sqlserver.jdbc.SQLServerDriver
#org.quartz.dataSource.myDS.URL = jdbc:sqlserver://127.0.0.1:1433;DatabaseName=SYS_MGR_TEST
#org.quartz.dataSource.myDS.user = sa
#org.quartz.dataSource.myDS.password = 123
#org.quartz.dataSource.myDS.maxConnections = 5
#============================================================== 
#Configure Cluster Properties 
#==============================================================
org.quartz.scheduler.instanceId = AUTO
org.quartz.scheduler.instanceName = DefaultQuartzScheduler
org.quartz.jobStore.isClustered = true 
org.quartz.jobStore.clusterCheckinInterval = 20000

#============================================================== 
#Configure ThreadPool 
#==============================================================
org.quartz.threadPool.class = org.quartz.simpl.SimpleThreadPool
org.quartz.threadPool.threadCount = 10
org.quartz.threadPool.threadPriority = 5
org.quartz.threadPool.threadsInheritContextClassLoaderOfInitializingThread = true

使用的是spring配置的数据源,

使用sqlserver的时候一切正常,使用oracle数据库,我就修改了org.quartz.jobStore.driverDelegateClass = org.quartz.impl.jdbcjobstore.oracle.OracleDelegate

结果启动的时候就报告上面那个异常。

哪位达人帮助看一下,多谢~~
问题补充
真的没有人知道吗?     
2009年12月03日 12:36

3个答案 按时间排序 按投票排序

0 0

是否数据库方言没有设置正确?
sql server:org.hibernate.dialect.SQLServerDialect
oracle:org.hibernate.dialect.Oracle9Dialect

2009年12月03日 19:04
0 0

是不是 RECOVERER  是oracle中的关键字?

2009年12月03日 12:36
0 0

ORA-00904 invalid column name
显然问题出在org.quartz.jobStore.selectWithLockSQL = SELECT * FROM {0}LOCKS WHERE LOCK_NAME = ?

2009年12月03日 12:36

相关推荐

Global site tag (gtag.js) - Google Analytics