[ 
https://issues.apache.org/jira/browse/SPARK-37315?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Dongjoon Hyun resolved SPARK-37315.
-----------------------------------
    Fix Version/s: 3.3.0
       Resolution: Fixed

Issue resolved by pull request 34583
[https://github.com/apache/spark/pull/34583]

> Mitigate ConcurrentModificationException thrown from a test in MLEventSuite
> ---------------------------------------------------------------------------
>
>                 Key: SPARK-37315
>                 URL: https://issues.apache.org/jira/browse/SPARK-37315
>             Project: Spark
>          Issue Type: Bug
>          Components: ML, Tests
>    Affects Versions: 3.3.0
>            Reporter: Kousuke Saruta
>            Assignee: Kousuke Saruta
>            Priority: Major
>             Fix For: 3.3.0
>
>
> Recently, I notice ConcurrentModificationException is sometimes thrown from 
> the following part of the test "pipeline read/write events" in MLEventSuite 
> when Scala 2.13 is used.
> {code}
> events.map(JsonProtocol.sparkEventToJson).foreach { event =>
>   assert(JsonProtocol.sparkEventFromJson(event).isInstanceOf[MLEvent])
> }
> {code}
> I think the root cause is the ArrayBuffer (events) is updated asynchronously 
> by the following part.
> {code}
> private val listener: SparkListener = new SparkListener {
>   override def onOtherEvent(event: SparkListenerEvent): Unit = event match {
>     case e: MLEvent => events.append(e)
>     case _ =>
>   }
> }
> {code}



--
This message was sent by Atlassian Jira
(v8.20.1#820001)

---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to