private JobCallable<QueueStatusBean> getJobStatusCallableTask(final String user,
                                 final String id) {
    return new JobCallable<QueueStatusBean>() {
      @Override
      public QueueStatusBean execute() throws NotAuthorizedException, BadParam, IOException,
                                    InterruptedException, BusyException {
       /*
        * Change the current thread name to include parent thread Id if it is executed
        * in thread pool. Useful to extract logs specific to a job request and helpful
        * to debug job issues.
        */
        Thread.currentThread().setName(String.format("%s-%s-%s", JOB_STATUS_EXECUTE_THREAD_PREFIX,
                                       statusThreadId, Thread.currentThread().getId()));

        return getJobStatus(user, id);
      }
    };
  }
Current thread id used to set in execution threads.
hcatalog/webhcat/svr/src/main/java/org/apache/hive/hcatalog/templeton/StatusDelegator.java