@Override public void start(HiveConf hiveConf) throws Exception { this.hiveConf = hiveConf; HiveTxnManager mgr = TxnManagerFactory.getTxnManagerFactory().getTxnManager(hiveConf); if(!mgr.supportsAcid()) { LOG.info(this.getClass().getName() + " not started since " + mgr.getClass().getName() + " does not support Acid."); return;//there are no transactions in this case } pool = Executors.newScheduledThreadPool(1, new ThreadFactory() { private final AtomicInteger threadCounter = new AtomicInteger(); @Override public Thread newThread(Runnable r) { return new Thread(r, HouseKeeperServiceBase.this.getClass().getName() + "-" + threadCounter.getAndIncrement()); } }); TimeUnit tu = TimeUnit.MILLISECONDS; pool.scheduleAtFixedRate(getScheduedAction(hiveConf, isAliveCounter), getStartDelayMs(), getIntervalMs(), tu); LOG.info("Started " + this.getClass().getName() + " with delay/interval = " + getStartDelayMs() + "/" + getIntervalMs() + " " + tu); }