You are viewing a plain text version of this content. The canonical link for it is here.
Posted to gitbox@hive.apache.org by GitBox <gi...@apache.org> on 2020/09/21 17:23:56 UTC

[GitHub] [hive] zabetak commented on a change in pull request #1509: HIVE-24179: Memory leak in HS2 DbTxnManager when compiling SHOW LOCKS statement

zabetak commented on a change in pull request #1509:
URL: https://github.com/apache/hive/pull/1509#discussion_r492225545



##########
File path: ql/src/java/org/apache/hadoop/hive/ql/ddl/table/lock/show/ShowDbLocksAnalyzer.java
##########
@@ -47,14 +47,16 @@ public void analyzeInternal(ASTNode root) throws SemanticException {
     String dbName = stripQuotes(root.getChild(0).getText());
     boolean isExtended = (root.getChildCount() > 1);
 
-    HiveTxnManager txnManager = null;
+    boolean useNewLocksFormat;
     try {
-      txnManager = TxnManagerFactory.getTxnManagerFactory().getTxnManager(conf);
+      HiveTxnManager txnManager = TxnManagerFactory.getTxnManagerFactory().getTxnManager(conf);

Review comment:
       That's correct. Normally, we should (but I am not 100% sure) have a TxnManager at this point so there is no need to create a new one just to obtain the flag. I pushed commit https://github.com/apache/hive/pull/1509/commits/297882ee80d52689a9cc1c68da9f7580918439bb to try this out.




----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



---------------------------------------------------------------------
To unsubscribe, e-mail: gitbox-unsubscribe@hive.apache.org
For additional commands, e-mail: gitbox-help@hive.apache.org