viirya commented on a change in pull request #25420: [SPARK-28699][Core] Cache 
an indeterminate RDD could lead to incorrect result while stage rerun
URL: https://github.com/apache/spark/pull/25420#discussion_r313067823
 
 

 ##########
 File path: 
sql/core/src/main/scala/org/apache/spark/sql/execution/columnar/InMemoryRelation.scala
 ##########
 @@ -86,7 +86,7 @@ case class CachedRDDBuilder(
 
   private def buildBuffers(): RDD[CachedBatch] = {
     val output = cachedPlan.output
-    val cached = cachedPlan.execute().mapPartitionsInternal { rowIterator =>
+    val cached = cachedPlan.execute().mapPartitionsWithIndexInternal({ (_, 
rowIterator) =>
 
 Review comment:
   I think we only run cached plan once. I think it should be determinate? If 
so, this map should not be order sensitive effectively?

----------------------------------------------------------------
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.
 
For queries about this service, please contact Infrastructure at:
[email protected]


With regards,
Apache Git Services

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

Reply via email to