You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@auron.apache.org by "yew1eb (via GitHub)" <gi...@apache.org> on 2025/12/10 13:36:46 UTC

[PR] [AURON #1725] Support Native CollectLimit [auron]

yew1eb opened a new pull request, #1726:
URL: https://github.com/apache/auron/pull/1726

   <!--
   Thanks for sending a pull request!  Please keep the following tips in mind:
     - Start the PR title with the related issue ID, e.g. '[AURON #XXXX] Short summary...'.
     - Make your PR title clear and descriptive, summarizing what this PR changes.
     - Provide a concise example to reproduce the issue, if possible.
     - Keep the PR description up to date with all changes.
   -->
   
   # Which issue does this PR close?
   
   <!--
   We generally require a GitHub issue to be filed for all bug fixes and enhancements and this helps us generate change logs for our releases. You can link an issue to this PR using the GitHub syntax. For example `Closes #123` indicates that this PR will close issue #123.
   -->
   
   Closes #1725 .
   
    # Rationale for this change
   <!--
    Why are you proposing this change? If this is already explained clearly in the issue then this section is not needed.
    Explaining clearly why changes are proposed helps reviewers understand your changes and offer better suggestions for fixes.  
   -->
   
   # What changes are included in this PR?
   <!--
   There is no need to duplicate the description in the issue here but it is sometimes worth providing a summary of the individual changes in this PR.
   -->
   
   # Are there any user-facing changes?
   <!--
   If there are user-facing changes then we may require documentation to be updated before approving the PR.
   -->
   
   <!--
   If there are any breaking changes to public APIs, please add the `api change` label.
   -->
   
   # How was this patch tested?
   <!--
   If tests were added, say they were added here. Please make sure to add some test cases that check the changes thoroughly including negative and positive cases if possible.
   If it was tested in a way different from regular unit tests, please clarify how you tested step by step, ideally copy and paste-able, so that other reviewers can test and check, and descendants can verify in the future.
   If tests were not added, please describe why they were not added and/or why it was difficult to add.
   -->
   


-- 
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: commits-unsubscribe@auron.apache.org

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


Re: [PR] [AURON #1725] Support Native CollectLimit [auron]

Posted by "cxzl25 (via GitHub)" <gi...@apache.org>.
cxzl25 commented on code in PR #1726:
URL: https://github.com/apache/auron/pull/1726#discussion_r2606705265


##########
spark-extension/src/main/scala/org/apache/spark/sql/auron/AuronConvertStrategy.scala:
##########
@@ -19,19 +19,7 @@ package org.apache.spark.sql.auron
 import org.apache.commons.lang3.reflect.MethodUtils
 import org.apache.spark.internal.Logging
 import org.apache.spark.sql.catalyst.trees.TreeNodeTag
-import org.apache.spark.sql.execution.ExpandExec
-import org.apache.spark.sql.execution.FileSourceScanExec
-import org.apache.spark.sql.execution.FilterExec
-import org.apache.spark.sql.execution.GenerateExec
-import org.apache.spark.sql.execution.GlobalLimitExec
-import org.apache.spark.sql.execution.LocalLimitExec
-import org.apache.spark.sql.execution.LocalTableScanExec
-import org.apache.spark.sql.execution.ProjectExec
-import org.apache.spark.sql.execution.SortExec
-import org.apache.spark.sql.execution.SparkPlan
-import org.apache.spark.sql.execution.TakeOrderedAndProjectExec
-import org.apache.spark.sql.execution.UnaryExecNode
-import org.apache.spark.sql.execution.UnionExec
+import org.apache.spark.sql.execution.{CollectLimitExec, ExpandExec, FileSourceScanExec, FilterExec, GenerateExec, GlobalLimitExec, LocalLimitExec, LocalTableScanExec, ProjectExec, SortExec, SparkPlan, TakeOrderedAndProjectExec, UnaryExecNode, UnionExec}

Review Comment:
   ```suggestion
   import org.apache.spark.sql.execution._
   ```



-- 
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: commits-unsubscribe@auron.apache.org

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


Re: [PR] [AURON #1725] Support Native CollectLimit [auron]

Posted by "cxzl25 (via GitHub)" <gi...@apache.org>.
cxzl25 commented on code in PR #1726:
URL: https://github.com/apache/auron/pull/1726#discussion_r2606776512


##########
spark-extension/src/main/scala/org/apache/spark/sql/auron/AuronConverters.scala:
##########
@@ -49,20 +49,7 @@ import org.apache.spark.sql.catalyst.plans.physical.HashPartitioning
 import org.apache.spark.sql.catalyst.plans.physical.Partitioning
 import org.apache.spark.sql.catalyst.plans.physical.RangePartitioning
 import org.apache.spark.sql.catalyst.plans.physical.RoundRobinPartitioning
-import org.apache.spark.sql.execution.ExpandExec
-import org.apache.spark.sql.execution.FileSourceScanExec
-import org.apache.spark.sql.execution.FilterExec
-import org.apache.spark.sql.execution.GenerateExec
-import org.apache.spark.sql.execution.GlobalLimitExec
-import org.apache.spark.sql.execution.LeafExecNode
-import org.apache.spark.sql.execution.LocalLimitExec
-import org.apache.spark.sql.execution.LocalTableScanExec
-import org.apache.spark.sql.execution.ProjectExec
-import org.apache.spark.sql.execution.SortExec
-import org.apache.spark.sql.execution.SparkPlan
-import org.apache.spark.sql.execution.TakeOrderedAndProjectExec
-import org.apache.spark.sql.execution.UnaryExecNode
-import org.apache.spark.sql.execution.UnionExec
+import org.apache.spark.sql.execution.{CollectLimitExec, ExpandExec, FileSourceScanExec, FilterExec, GenerateExec, GlobalLimitExec, LeafExecNode, LocalLimitExec, LocalTableScanExec, ProjectExec, SortExec, SparkPlan, TakeOrderedAndProjectExec, UnaryExecNode, UnionExec}

Review Comment:
   ```suggestion
   import org.apache.spark.sql.execution._
   ```



-- 
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: commits-unsubscribe@auron.apache.org

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


Re: [PR] [AURON #1725] Support Native CollectLimit [auron]

Posted by "cxzl25 (via GitHub)" <gi...@apache.org>.
cxzl25 commented on code in PR #1726:
URL: https://github.com/apache/auron/pull/1726#discussion_r2609122390


##########
spark-extension/src/main/scala/org/apache/spark/sql/auron/Shims.scala:
##########
@@ -123,6 +123,8 @@ abstract class Shims {
 
   def createNativeLocalLimitExec(limit: Long, child: SparkPlan): NativeLocalLimitBase
 
+  def createNativeCollectLimitExec(limit: Int, child: SparkPlan): NativeCollectLimitBase

Review Comment:
   Do we also need to consider the offset syntax introduced in 3.4?
   
   [SPARK-28330][SQL] Support ANSI SQL: result offset clause in query expression



-- 
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: commits-unsubscribe@auron.apache.org

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


Re: [PR] [AURON #1725] Support Native CollectLimit [auron]

Posted by "yew1eb (via GitHub)" <gi...@apache.org>.
yew1eb commented on code in PR #1726:
URL: https://github.com/apache/auron/pull/1726#discussion_r2609172632


##########
spark-extension/src/main/scala/org/apache/spark/sql/auron/Shims.scala:
##########
@@ -123,6 +123,8 @@ abstract class Shims {
 
   def createNativeLocalLimitExec(limit: Long, child: SparkPlan): NativeLocalLimitBase
 
+  def createNativeCollectLimitExec(limit: Int, child: SparkPlan): NativeCollectLimitBase

Review Comment:
   > Do we also need to consider the offset syntax introduced in 3.4?
   > 
   > [SPARK-28330][SQL] Support ANSI SQL: result offset clause in query expression
   
   Yes, I plan to open a separate issue to support LIMIT with OFFSET.



-- 
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: commits-unsubscribe@auron.apache.org

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


Re: [PR] [AURON #1725] Support Native CollectLimit [auron]

Posted by "yew1eb (via GitHub)" <gi...@apache.org>.
yew1eb commented on PR #1726:
URL: https://github.com/apache/auron/pull/1726#issuecomment-3654388702

   @richox CI is green, PTAL


-- 
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: commits-unsubscribe@auron.apache.org

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


Re: [PR] [AURON #1725] Support Native CollectLimit [auron]

Posted by "richox (via GitHub)" <gi...@apache.org>.
richox commented on code in PR #1726:
URL: https://github.com/apache/auron/pull/1726#discussion_r2609138248


##########
spark-extension/src/main/scala/org/apache/spark/sql/auron/Shims.scala:
##########
@@ -123,6 +123,8 @@ abstract class Shims {
 
   def createNativeLocalLimitExec(limit: Long, child: SparkPlan): NativeLocalLimitBase
 
+  def createNativeCollectLimitExec(limit: Int, child: SparkPlan): NativeCollectLimitBase

Review Comment:
   we can just fallback for limits with offsets, and implement them in another pr



-- 
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: commits-unsubscribe@auron.apache.org

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


Re: [PR] [AURON #1725] Support Native CollectLimit [auron]

Posted by "cxzl25 (via GitHub)" <gi...@apache.org>.
cxzl25 merged PR #1726:
URL: https://github.com/apache/auron/pull/1726


-- 
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: commits-unsubscribe@auron.apache.org

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