hive-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From pv...@apache.org
Subject hive git commit: HIVE-17072: Make the parallelized timeout configurable in BeeLine tests (Marta Kuczora, reviewed by Peter Vary)
Date Wed, 26 Jul 2017 09:01:54 GMT
Repository: hive
Updated Branches:
  refs/heads/master 884553c62 -> 0836d1a65


HIVE-17072: Make the parallelized timeout configurable in BeeLine tests (Marta Kuczora, reviewed
by Peter Vary)


Project: http://git-wip-us.apache.org/repos/asf/hive/repo
Commit: http://git-wip-us.apache.org/repos/asf/hive/commit/0836d1a6
Tree: http://git-wip-us.apache.org/repos/asf/hive/tree/0836d1a6
Diff: http://git-wip-us.apache.org/repos/asf/hive/diff/0836d1a6

Branch: refs/heads/master
Commit: 0836d1a650b86b09408b92f516fed06fe08f420f
Parents: 884553c
Author: Peter Vary <pvary@cloudera.com>
Authored: Wed Jul 26 11:00:48 2017 +0200
Committer: Peter Vary <pvary@cloudera.com>
Committed: Wed Jul 26 11:00:48 2017 +0200

----------------------------------------------------------------------
 .../src/main/java/org/apache/hive/beeline/Parallelized.java     | 5 ++++-
 1 file changed, 4 insertions(+), 1 deletion(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/hive/blob/0836d1a6/itests/util/src/main/java/org/apache/hive/beeline/Parallelized.java
----------------------------------------------------------------------
diff --git a/itests/util/src/main/java/org/apache/hive/beeline/Parallelized.java b/itests/util/src/main/java/org/apache/hive/beeline/Parallelized.java
index a819e26..5cef4c7 100644
--- a/itests/util/src/main/java/org/apache/hive/beeline/Parallelized.java
+++ b/itests/util/src/main/java/org/apache/hive/beeline/Parallelized.java
@@ -30,6 +30,7 @@ import java.util.concurrent.TimeUnit;
  */
 public class Parallelized extends Parameterized {
   private static class ThreadPoolScheduler implements RunnerScheduler {
+    private static final String DEFAULT_TIMEOUT = "10";
     private ExecutorService executor;
 
     public ThreadPoolScheduler() {
@@ -45,7 +46,9 @@ public class Parallelized extends Parameterized {
     public void finished() {
       executor.shutdown();
       try {
-        executor.awaitTermination(10, TimeUnit.MINUTES);
+        String timeoutProp = System.getProperty("junit.parallel.timeout", DEFAULT_TIMEOUT);
+        long timeout = Long.parseLong(timeoutProp);
+        executor.awaitTermination(timeout, TimeUnit.MINUTES);
       } catch (InterruptedException exc) {
         throw new RuntimeException(exc);
       }


Mime
View raw message