<bean id="taskExecutor"
class="org.springframework.scheduling.concurrent.ThreadPoolTaskExecutor">
<property name="corePoolSize" value="5" />
<property name="maxPoolSize" value="15" />
<property name="queueCapacity" value="25" />
</bean>
<bean id="companyTimeTaskExecutorQueueConsumer"
class="cn.sh.online.comment.util.timer.CompanyTimeTaskExecutorQueueConsumer">
<constructor-arg ref="taskExecutor" />
<constructor-arg ref="commentContentService" />
<constructor-arg ref="timerIpFilter" />
<constructor-arg ref="timerKeywordFilter" />
<constructor-arg ref="timerBlackNameFilter" />
</bean>
<bean id="restTimeTaskExecutorQueueConsumer"
class="cn.sh.online.comment.util.timer.RestTimeTaskExecutorQueueConsumer">
<constructor-arg ref="taskExecutor" />
<constructor-arg ref="commentContentService" />
<constructor-arg ref="timerIpFilter" />
<constructor-arg ref="timerKeywordFilter" />
<constructor-arg ref="timerBlackNameFilter" />
</bean>
<bean id="companyTimeJob"
class="org.springframework.scheduling.quartz.MethodInvokingJobDetailFactoryBean">
<property name="targetObject">
<ref bean="companyTimeTaskExecutorQueueConsumer" />
</property>
<property name="targetMethod">
<value>eatCommentContentFrontDto</value>
</property>
</bean>
<bean id="restTimeJob"
class="org.springframework.scheduling.quartz.MethodInvokingJobDetailFactoryBean">
<property name="targetObject">
<ref bean="restTimeTaskExecutorQueueConsumer" />
</property>
<property name="targetMethod">
<value>eatCommentContentFrontDto</value>
</property>
</bean>
<bean id="companyTimeCron"
class="org.springframework.scheduling.quartz.CronTriggerBean">
<property name="jobDetail">
<ref bean="companyTimeJob" />
</property>
<property name="cronexpression_r_r">
<value>*/5 * 0-7 * * ?</value>
</property>
</bean>
<bean id="restTimeCron"
class="org.springframework.scheduling.quartz.CronTriggerBean">
<property name="jobDetail">
<ref bean="restTimeJob" />
</property>
<property name="cronexpression_r_r">
<value>*/5 * 8-17 * * ?</value>
</property>
</bean>
<bean autowire="no"
class="org.springframework.scheduling.quartz.SchedulerFactoryBean">
<property name="triggers">
<list>
<ref local="companyTimeCron" />
<ref local="restTimeCron" />
</list>
</property>
</bean>