cloud-fan commented on a change in pull request #27941: [SPARK-31178][SQL]
Prevent V2 exec nodes from executing multiple times
URL: https://github.com/apache/spark/pull/27941#discussion_r394082821
##########
File path:
sql/core/src/main/scala/org/apache/spark/sql/execution/datasources/v2/WriteToDataSourceV2Exec.scala
##########
@@ -347,10 +347,26 @@ trait BatchWriteHelper {
}
}
+/**
+ * A base trait for executing a write eagerly and caching the result, similar
to
+ * `ExecutedCommandExec`, so that a write is executed only once.
+ */
+trait V2TableWriteExecBase extends SparkPlan {
Review comment:
can we reuse `V2CommandExec`? The major difference is the return type of
`run`, but I don't think there is a command that must return an RDD.
----------------------------------------------------------------
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]