You are viewing a plain text version of this content. The canonical link for it is here.
Posted to reviews@spark.apache.org by GitBox <gi...@apache.org> on 2022/04/25 13:53:08 UTC

[GitHub] [spark] srowen commented on a diff in pull request #36262: [SPARK-38944][CORE][SQL] Close `UnsafeSorterSpillReader` before `SpillableArrayIterator` throw `ConcurrentModificationException`

srowen commented on code in PR #36262:
URL: https://github.com/apache/spark/pull/36262#discussion_r857652454


##########
sql/core/src/main/scala/org/apache/spark/sql/execution/ExternalAppendOnlyUnsafeRowArray.scala:
##########
@@ -228,6 +234,11 @@ private[sql] class ExternalAppendOnlyUnsafeRowArray(
       currentRow.pointTo(iterator.getBaseObject, iterator.getBaseOffset, iterator.getRecordLength)
       currentRow
     }
+
+    override protected def closeIfNeed(): Unit = iterator match {

Review Comment:
   IfNeed -> IfNeeded



##########
sql/core/src/test/scala/org/apache/spark/sql/execution/ExternalAppendOnlyUnsafeRowArraySuite.scala:
##########
@@ -56,7 +59,7 @@ class ExternalAppendOnlyUnsafeRowArraySuite extends SparkFunSuite with LocalSpar
   private def insertRow(array: ExternalAppendOnlyUnsafeRowArray): Long = {
     val valueInserted = random.nextLong()
 
-    val row = new UnsafeRow(1)
+    val row = new UnsafeRow(  1)

Review Comment:
   (revert)



-- 
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.

To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org
For additional commands, e-mail: reviews-help@spark.apache.org