cryptoe commented on code in PR #16248:
URL: https://github.com/apache/druid/pull/16248#discussion_r1562325407
##########
sql/src/main/java/org/apache/druid/sql/calcite/planner/CalciteRulesManager.java:
##########
@@ -95,12 +100,16 @@ public class CalciteRulesManager
* and {@link CoreRules#FILTER_INTO_JOIN}, which are part of {@link
#FANCY_JOIN_RULES}.
* 4) {@link CoreRules#PROJECT_FILTER_TRANSPOSE} because PartialDruidQuery
would like to have the Project on top of the Filter -
* this rule could create a lot of non-useful plans.
+ *
+ * {@link CoreRules#PROJECT_MERGE} includes configurable bloat parameter, as
a workaround for Calcite exception
+ * (there are not enough rules to produce a node with desired properties)
thrown while running complex sql-queries with
+ * big amount of subqueries. `druid.sql.planner.bloat` should be set in
broker's `jvm.config` file.
*/
private static final List<RelOptRule> BASE_RULES =
ImmutableList.of(
CoreRules.AGGREGATE_STAR_TABLE,
CoreRules.AGGREGATE_PROJECT_STAR_TABLE,
- CoreRules.PROJECT_MERGE,
+ ProjectMergeRule.Config.DEFAULT.withBloat(BLOAT).toRule(),
Review Comment:
How do users know when to set this context parameter ?
I think we should change the error message so that they can be a bit more
helpful for the end users.
--
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]