[ 
https://issues.apache.org/jira/browse/SPARK-31592?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=17096743#comment-17096743
 ] 

Apache Spark commented on SPARK-31592:
--------------------------------------

User 'fanyunbojerry' has created a pull request for this issue:
https://github.com/apache/spark/pull/28389

> 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.3
>            Reporter: Yunbo Fan
>            Priority: Major
>
> 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

Reply via email to