use of com.dtstack.taier.common.CustomThreadRunsPolicy in project Taier by DTStack.
the class AbstractJobSummitScheduler method afterPropertiesSet.
@Override
public void afterPropertiesSet() throws Exception {
super.afterPropertiesSet();
scheduleJobQueue = new LinkedBlockingQueue<>(env.getQueueSize());
String threadName = this.getClass().getSimpleName() + "_" + getSchedulerName() + "_startJobProcessor";
executorService = new ThreadPoolExecutor(env.getJobExecutorPoolCorePoolSize(), env.getJobExecutorPoolMaximumPoolSize(), env.getJobExecutorPoolKeepAliveTime(), TimeUnit.MILLISECONDS, new LinkedBlockingQueue<>(env.getJobExecutorPoolQueueSize()), new CustomThreadFactory(threadName), new CustomThreadRunsPolicy(threadName, getSchedulerName()));
}
Aggregations