gortiz commented on code in PR #19944:
URL: https://github.com/apache/pinot/pull/19944#discussion_r4630729022


##########
pinot-spi/src/main/java/org/apache/pinot/spi/utils/CommonConstants.java:
##########
@@ -648,10 +648,19 @@ public static class Broker {
     public static final String CONFIG_OF_INFER_PARTITION_HINT = 
"pinot.broker.multistage.infer.partition.hint";
     public static final boolean DEFAULT_INFER_PARTITION_HINT = false;
 
-    /// Whether to use spools in multistage query engine by default.
+    /// The default spool mode of the multistage query engine: `off`, `auto` 
or `on`. `false` and `no` are aliases of
+    /// `off`, and `true` and `yes` are aliases of `on`.
+    ///
+    /// - `off` never shares a stage between consumers.
+    /// - `auto` shares a stage only when the planner can prove that the 
sharing cannot block the query.
+    /// - `on` shares every equivalent stage that the planner supports, 
without that safety check.
+    ///
+    /// Only the default planner applies spools. With 
[Request.QueryOptionKey#USE_PHYSICAL_OPTIMIZER] the mode is
+    /// ignored.
+    ///
     /// This value can always be overridden by 
[Request.QueryOptionKey#USE_SPOOLS] query option
     public static final String CONFIG_OF_SPOOLS = 
"pinot.broker.multistage.spools";
-    public static final boolean DEFAULT_OF_SPOOLS = false;
+    public static final String DEFAULT_SPOOLS_MODE = "auto";

Review Comment:
   I'd rather keep it removed than add a deprecated alias. Nothing reads that 
constant anymore: the planner now takes the mode from `useSpools` 
(off/auto/on), with `DEFAULT_SPOOLS_MODE = "auto"` as the default. An alias 
would keep a plugin compiling while its value (`false`) no longer matches what 
the broker does, so the plugin would configure something that is silently 
ignored. A compile error is better: it points the author to 
`DEFAULT_SPOOLS_MODE`. Code that is already compiled has the boolean inlined 
and keeps working. So this needs a maintainer to accept the source-level SPI 
break and waive the Binary Compatibility Check for this field.
   



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