Github user cloud-fan commented on a diff in the pull request:
https://github.com/apache/spark/pull/20726#discussion_r172307625
--- Diff:
sql/core/src/main/scala/org/apache/spark/sql/execution/datasources/v2/DataSourceV2ScanExec.scala
---
@@ -46,34 +48,46 @@ case class DataSourceV2ScanExec(
new DataSourcePartitioning(
s.outputPartitioning(), AttributeMap(output.map(a => a -> a.name)))
+ case _ if readerFactories.size == 1 => SinglePartition
--- End diff --
shall we move it before `case s: SupportsReportPartitioning`? the
difference is, shall we always report `SinglePartition` if there is only one
writer factory. By looking at `EnsureRequirements`, seems `SinglePartition` is
more likely to satisfy the distribution.
---
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]