liviazhu-db commented on code in PR #49816:
URL: https://github.com/apache/spark/pull/49816#discussion_r1945645134


##########
sql/catalyst/src/main/scala/org/apache/spark/sql/internal/SQLConf.scala:
##########
@@ -2251,6 +2251,22 @@ object SQLConf {
       .booleanConf
       .createWithDefault(true)
 
+  val STATE_STORE_PARTITION_METRICS_REPORT_LIMIT =
+    buildConf("spark.sql.streaming.stateStore.numPartitionMetricsToReport")
+      .internal()
+      .doc(
+        "Maximum number of partition-level metrics to include in state store 
progress " +
+          "reporting. The default limit is 20% of the number of cores (with a 
minimum of 1 " +
+          "partition) and with a cap of 10. This limits the metrics to the N 
partitions with " +
+          "the smallest values to prevent the progress report from becoming 
too large."
+      )
+      .version("4.0.0")
+      .intConf
+      .checkValue(k => k >= 0, "Must be greater than or equal to 0")
+      .createWithDefault(
+        Math.min(10, Math.min(1, 
SHUFFLE_PARTITIONS.defaultValue.getOrElse(200) / 5))

Review Comment:
   Yes but it just uses the default, right? I guess the use of that is if we 
want to tolerate when the default value changes, but I can't imagine the the 
default going lower than 50 (which is what it would be need to be for this 
default to be anything but 10).



-- 
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: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]


---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to