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/03/15 15:02:56 UTC

[GitHub] [spark] cloud-fan commented on a change in pull request #35710: [SPARK-38391][SQL] Datasource v2 supports partial topN push-down

cloud-fan commented on a change in pull request #35710:
URL: https://github.com/apache/spark/pull/35710#discussion_r827081236



##########
File path: sql/catalyst/src/main/java/org/apache/spark/sql/connector/read/SupportsPushDownTopN.java
##########
@@ -31,8 +31,23 @@
 @Evolving
 public interface SupportsPushDownTopN extends ScanBuilder {
 
+    /**
+     * The first element of tuple means topN can be pushed down to data source.
+     * The second element of tuple is false means Spark complete push down topN,
+     * otherwise means Spark partial push down topN and need preserves sort too.
+     */
+    class Tuple {
+        public final Boolean enable;
+        public final Boolean isPartial;

Review comment:
       2 boolean means we should have two methods... You did it right at the beginning, why do you change the API?




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