Uploaded image for project: 'Hive'
  1. Hive
  2. HIVE-21425

Use DirectExecutorService for getInputSummary

    XMLWordPrintableJSON

Details

    Description

      Utilities.java
            int numExecutors = getMaxExecutorsForInputListing(ctx.getConf(), pathNeedProcess.size());
            if (numExecutors > 1) {
              LOG.info("Using {} threads for getContentSummary", numExecutors);
              executor = Executors.newFixedThreadPool(numExecutors,
                      new ThreadFactoryBuilder().setDaemon(true)
                              .setNameFormat("Get-Input-Summary-%d").build());
            } else {
              executor = null;
            }
      

      https://github.com/apache/hive/blob/master/ql/src/java/org/apache/hadoop/hive/ql/exec/Utilities.java#L2482-L2490

      Instead of using a 'null' ExecutorService, use Guava's DirectExecutorService and remove special casing for a 'null' value.

      Attachments

        1. HIVE-21425.1.patch
          3 kB
          David Mollitor
        2. HIVE-21425.1.patch
          3 kB
          David Mollitor
        3. HIVE-21425.1.patch
          3 kB
          David Mollitor

        Issue Links

          Activity

            People

              belugabehr David Mollitor
              belugabehr David Mollitor
              Votes:
              0 Vote for this issue
              Watchers:
              2 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved:

                Time Tracking

                  Estimated:
                  Original Estimate - Not Specified
                  Not Specified
                  Remaining:
                  Remaining Estimate - 0h
                  0h
                  Logged:
                  Time Spent - 0.5h
                  0.5h