belugabehr commented on a change in pull request #2312:
URL: https://github.com/apache/hive/pull/2312#discussion_r639713660
##########
File path:
ql/src/java/org/apache/hadoop/hive/ql/cache/results/QueryResultsCache.java
##########
@@ -493,20 +491,17 @@ public CacheEntry addToCache(QueryInfo queryInfo,
ValidTxnWriteIdList txnWriteId
addedEntry.queryInfo = queryInfo;
addedEntry.txnWriteIdList = txnWriteIdList;
- Lock writeLock = rwLock.writeLock();
+ cacheWriteLock.lock();
try {
- writeLock.lock();
-
Review comment:
Move locks outside the try block as is the official Java Trails way.
--
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:
[email protected]
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]