Yunbo Fan created SPARK-31592: --------------------------------- Summary: bufferPoolsBySize in HeapMemoryAllocator should be thread safe Key: SPARK-31592 URL: https://issues.apache.org/jira/browse/SPARK-31592 Project: Spark Issue Type: Bug Components: Spark Core Affects Versions: 2.4.5 Reporter: Yunbo Fan
Currently, bufferPoolsBySize in HeapMemoryAllocator uses a Map type whose value type is LinkedList. LinkedList is not thread safe and may hit the error below {code:java} java.util.NoSuchElementExceptionException at java.util.LinkedList.removeFirst(LinkedList.java:270) at java.util.LinkedList.remove(LinkedList.java:685) at org.apache.spark.unsafe.memory.HeapMemoryAllocator.allocate(HeapMemoryAllocator.java:57){code} -- This message was sent by Atlassian Jira (v8.3.4#803005) --------------------------------------------------------------------- To unsubscribe, e-mail: issues-unsubscr...@spark.apache.org For additional commands, e-mail: issues-h...@spark.apache.org