baigd created HIVE-11917: ---------------------------- Summary: Report a possible race issue Key: HIVE-11917 URL: https://issues.apache.org/jira/browse/HIVE-11917 Project: Hive Issue Type: Bug Reporter: baigd Priority: Critical
Hi, Developers of apache/hive, I am writing to report a race issue on use of ConcurrentHashMap. The issue is reported by our tool in an automatic way. Although manually confirmed, it would be a false positive, given we do not know the specification of the program. We would very appreciate if you could check below for details and confirm with us whether it is a real problem. For more information, please refer to our website: http://sav.sutd.edu.sg/?page_id=2845 File: "apache/hive/ql/src/java/org/apache/hadoop/hive/ql/exec/spark/SmallTableCache.java" Location: Line (61,45/46/49) Description: The check-get-clear operations (line 45,46 and 49) in method "initialize()" is guarded by lock "tableContainerMap". I assume the intention is to guarantee the atomicity of the check-get-clear operation. However the put operation in line 61 is not properly locked, therefore it may break the atomicity of the check-get-clear operation in method "initialize()". Relying on the ConcurrentHashMap to ensure exclusive access is dangerous since ConcurrentHashMap has no guarantee of exclusive access. -- This message was sent by Atlassian JIRA (v6.3.4#6332)