集群石英2.x工作+弹簧4.1

时间:2015-08-18 13:22:14

标签: spring quartz-scheduler

我将弹簧与石英集成在一起,下面是我使用过的配置:

 <bean id="quartzScheduler" class="org.springframework.scheduling.quartz.SchedulerFactoryBean">
        <property name="dataSource">
            <ref bean="jndiDataSource"/>
        </property>
        <property name="applicationContextSchedulerContextKey">
            <value>applicationContext</value>
        </property>
        <property name="schedulerName" value="PimsJobs"/>
        <property name="quartzProperties">
            <props>
                <prop key="org.quartz.jobStore.driverDelegateClass">org.quartz.impl.jdbcjobstore.StdJDBCDelegate</prop>
                <prop key="org.quartz.jobStore.isClustered">true</prop>

            </props>
        </property>
    </bean>

虽然我已将属性isClustered设为true仍然在日志中看到

 [org.quartz.core.QuartzScheduler] (ServerService Thread Pool -- 108) Scheduler PimsJobs_$_NON_CLUSTERED started.

我也看到下面的日志:

36:31,747 INFO  [org.springframework.scheduling.quartz.SchedulerFactoryBean] (ServerService Thread Pool -- 108) Starting Quartz Scheduler now
    36:31,765 INFO  [org.springframework.scheduling.quartz.LocalDataSourceJobStore] (ServerService Thread Pool -- 108) ClusterManager: detected 1 failed or resta
    d instances.
    36:31,766 INFO  [org.springframework.scheduling.quartz.LocalDataSourceJobStore] (ServerService Thread Pool -- 108) ClusterManager: Scanning for instance "NON
    USTERED"'s failed in-progress jobs.

0 个答案:

没有答案