hive-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From hashut...@apache.org
Subject svn commit: r1471636 - /hive/branches/branch-0.11/ql/src/java/org/apache/hadoop/hive/ql/profiler/HiveProfilerStatsAggregator.java
Date Wed, 24 Apr 2013 20:19:33 GMT
Author: hashutosh
Date: Wed Apr 24 20:19:32 2013
New Revision: 1471636

URL: http://svn.apache.org/r1471636
Log:
HIVE-4308 : Newly added test TestCliDriver.hiveprofiler_union0 is failing on trunk (Navis
via Namit Jain)

Modified:
    hive/branches/branch-0.11/ql/src/java/org/apache/hadoop/hive/ql/profiler/HiveProfilerStatsAggregator.java

Modified: hive/branches/branch-0.11/ql/src/java/org/apache/hadoop/hive/ql/profiler/HiveProfilerStatsAggregator.java
URL: http://svn.apache.org/viewvc/hive/branches/branch-0.11/ql/src/java/org/apache/hadoop/hive/ql/profiler/HiveProfilerStatsAggregator.java?rev=1471636&r1=1471635&r2=1471636&view=diff
==============================================================================
--- hive/branches/branch-0.11/ql/src/java/org/apache/hadoop/hive/ql/profiler/HiveProfilerStatsAggregator.java
(original)
+++ hive/branches/branch-0.11/ql/src/java/org/apache/hadoop/hive/ql/profiler/HiveProfilerStatsAggregator.java
Wed Apr 24 20:19:32 2013
@@ -21,7 +21,6 @@ package org.apache.hadoop.hive.ql.profil
 import java.util.HashMap;
 import java.util.Map;
 import java.sql.ResultSet;
-import java.sql.ResultSetMetaData;
 import java.sql.PreparedStatement;
 import java.sql.SQLException;
 
@@ -58,7 +57,7 @@ public class HiveProfilerStatsAggregator
   }
 
 
-  private void populateAggregateStats(HiveConf conf) {
+  private void populateAggregateStats(HiveConf conf) throws SQLException {
     int waitWindow = rawProfileConnInfo.getWaitWindow();
     int maxRetries = rawProfileConnInfo.getMaxRetries();
 
@@ -83,9 +82,10 @@ public class HiveProfilerStatsAggregator
 
       populateAggregateStats(result);
       getProfileStatsStmt.close();
-      rawProfileConnInfo.getConnection().close();
     } catch(Exception e) {
       LOG.error("executing error: ", e);
+    } finally {
+      HiveProfilerUtils.closeConnection(rawProfileConnInfo);
     }
   }
 



Mime
View raw message