Hi everyone,
We recently upgraded our Quartz implementation from 1.x to 2.1.6. Among other changes, we had ro replace our references to CronTriggerBean, with the Quartz 2.1 compatible CronTriggerFactoryBean. After doing that, my app won't start. The specific error I am getting is:
It appears that CronTriggerFactoryBean is sticking the jobDetail into the trigger's jobDataMap, and now Quartz is trying to serialize it and save it to the DB. Specifically, in the afterPropertiesSet() method, there is the following code:Code:Caused by: java.io.IOException: JobDataMap values must be Strings when the 'useProperties' property is set. Key of offending value: jobDetail at org.quartz.impl.jdbcjobstore.StdJDBCDelegate.convertToProperty(StdJDBCDelegate.java:3113) at org.quartz.impl.jdbcjobstore.StdJDBCDelegate.serializeProperties(StdJDBCDelegate.java:3080) at org.quartz.impl.jdbcjobstore.StdJDBCDelegate.serializeJobData(StdJDBCDelegate.java:3032) at org.quartz.impl.jdbcjobstore.StdJDBCDelegate.insertTrigger(StdJDBCDelegate.java:1052) at org.quartz.impl.jdbcjobstore.JobStoreSupport.storeTrigger(JobStoreSupport.java:1209)
The old CronTriggerBean didn't do this. Any idea why it is doing this and how I can make the error go away? I don't understand why you would put the job detail into the jobDataMap. Changing the "useProperties" flag isn't an option because I need to use the jobDatMap for legitimate String data.Code:if (this.jobDetail != null) { this.jobDataMap.put(JobDetailAwareTrigger.JOB_DETAIL_KEY, this.jobDetail); }
Has anyone else seen this issue?
Thanks in advance for the help!
Joe


Reply With Quote
