private JobCallable<List<JobItemBean>> getJobListTask(final String user, final boolean showall,
                      final String jobId, final int numRecords, final boolean showDetails) {
    return new JobCallable<List<JobItemBean>>() {
      @Override
      public List<JobItemBean> execute() throws NotAuthorizedException, BadParam, IOException,
                                             InterruptedException {
       /*
        * 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_LIST_EXECUTE_THREAD_PREFIX,
                                       listThreadId, Thread.currentThread().getId()));

        return listJobs(user, showall, jobId, numRecords, showDetails);
      }
    };
  }
Current thread id used to set in execution threads.
hcatalog/webhcat/svr/src/main/java/org/apache/hive/hcatalog/templeton/ListDelegator.java