<bean id="parserJob4Pos" class="org.springframework.scheduling.quartz.JobDetailBean"> <property name="jobClass"> <!-- 这里的myQuartzJobBean需要继承QuartzJobBean --> <value>com.bejson.com.myQuartzJobBean</value> </property> </bean> <bean id="cronParserTrigger4Pos" class="org.springframework.scheduling.quartz.CronTriggerBean"> <property name="jobDetail" ref="parserJob4Pos" /> <property name="cronExpression"> <value>0 0/1 * * * ?</value> </property> </bean> <bean class="org.springframework.scheduling.quartz.SchedulerFactoryBean"> <property name="triggers"> <list> <ref bean="cronParserTrigger4Pos" /> </list> </property> </bean>
时间: 2024-10-10 02:54:01