marin-ma commented on code in PR #6670:
URL: https://github.com/apache/incubator-gluten/pull/6670#discussion_r1701373367


##########
shims/common/src/main/scala/org/apache/gluten/GlutenConfig.scala:
##########
@@ -305,14 +305,32 @@ class GlutenConfig(conf: SQLConf) extends Logging {
 
   def veloxBloomFilterMaxNumBits: Long = 
conf.getConf(COLUMNAR_VELOX_BLOOM_FILTER_MAX_NUM_BITS)
 
-  def veloxCoalesceBatchesBeforeShuffle: Boolean =
-    conf.getConf(COLUMNAR_VELOX_COALESCE_BATCHES_BEFORE_SHUFFLE)
+  case class ResizeRange(min: Int, max: Int) {
+    assert(max >= min)
+    assert(min > 0, "Min batch size should be larger than 0")
+    assert(max > 0, "Max batch size should be larger than 0")
+  }
+
+  private object ResizeRange {
+    def parse(pattern: String): ResizeRange = {
+      assert(pattern.count(_ == '~') == 1, s"Invalid range pattern for batch 
resizing: $pattern")
+      val splits = pattern.split('~')
+      assert(splits.length == 2)
+      ResizeRange(splits(0).toInt, splits(1).toInt)

Review Comment:
   Should we check the min size always < `COLUMNAR_MAX_BATCH_SIZE` and max size 
> `COLUMNAR_MAX_BATCH_SIZE` ?



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