@Override
      public void run() {
        try {
          SessionState.setCurrentSessionState(initSessionState);
          runRestartThread();
        } catch (Exception e) {
          LOG.warn("Exception in TezSessionPool-cleanup thread. Thread will shut down", e);
        } finally {
          LOG.info("TezSessionPool-cleanup thread exiting");
        }
      }
The background restart queue that is populated when expiration is triggered by a foreground
thread (i.e. getting or returning a session), to avoid delaying it.
ql/src/java/org/apache/hadoop/hive/ql/exec/tez/SessionExpirationTracker.java