You are viewing a plain text version of this content. The canonical link for it is here.
Posted to notifications@kyuubi.apache.org by GitBox <gi...@apache.org> on 2022/03/27 06:06:11 UTC

[GitHub] [incubator-kyuubi] yaooqinn commented on a change in pull request #2225: Support to set result max rows for spark engine

yaooqinn commented on a change in pull request #2225:
URL: https://github.com/apache/incubator-kyuubi/pull/2225#discussion_r835856217



##########
File path: externals/kyuubi-spark-sql-engine/src/main/scala/org/apache/kyuubi/engine/spark/operation/SparkSQLOperationManager.scala
##########
@@ -64,7 +65,15 @@ class SparkSQLOperationManager private (name: String) extends OperationManager(n
             case NONE =>
               val incrementalCollect = spark.conf.getOption(OPERATION_INCREMENTAL_COLLECT.key)
                 .map(_.toBoolean).getOrElse(operationIncrementalCollectDefault)
-              new ExecuteStatement(session, statement, runAsync, queryTimeout, incrementalCollect)
+              val resultMaxRows = spark.conf.getOption(ENGINE_SPARK_MAX_ROWS.key)

Review comment:
       move to ExecuteStatement

##########
File path: kyuubi-common/src/main/scala/org/apache/kyuubi/config/KyuubiConf.scala
##########
@@ -626,6 +626,14 @@ object KyuubiConf {
       .intConf
       .createWithDefault(1000000)
 
+  val ENGINE_SPARK_MAX_ROWS: ConfigEntry[Int] =
+    buildConf("session.engine.spark.max.rows")

Review comment:
       kyuubi.operation.max.result.rows?

##########
File path: kyuubi-common/src/main/scala/org/apache/kyuubi/config/KyuubiConf.scala
##########
@@ -626,6 +626,14 @@ object KyuubiConf {
       .intConf
       .createWithDefault(1000000)
 
+  val ENGINE_SPARK_MAX_ROWS: ConfigEntry[Int] =
+    buildConf("session.engine.spark.max.rows")
+      .doc("Max rows of Spark query results. Rows that exceeds the limit would be ignored. " +
+        "By setting this value to -1 to disable the max rows limit.")

Review comment:
       0




-- 
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: notifications-unsubscribe@kyuubi.apache.org

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



---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@kyuubi.apache.org
For additional commands, e-mail: notifications-help@kyuubi.apache.org