public static ScheduledExecutorService newScheduledThreadPool(int corePoolSize, String poolName) {
    logger.info(NEW_SCHEDULED_THREAD_POOL_LOGGER_FORMAT, poolName);
    return new WrappedScheduledExecutorService(
        Executors.newScheduledThreadPool(corePoolSize, new IoTThreadFactory(poolName)), poolName);
  }
see {@link Executors#newScheduledThreadPool(int, java.util.concurrent.ThreadFactory)}.

@param corePoolSize the number of threads to keep in the pool.
@param poolName the name of thread pool.
@return thread pool.
iotdb-core/node-commons/src/main/java/org/apache/iotdb/commons/concurrent/IoTDBThreadPoolFactory.java