Skip to content

Commit

Permalink
Feature flag disabling evaluation for queries with groupby functions
Browse files Browse the repository at this point in the history
  • Loading branch information
apmoriarty committed Jan 22, 2025
1 parent 970f950 commit 2cb9dae
Show file tree
Hide file tree
Showing 2 changed files with 13 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -348,6 +348,10 @@ public class DefaultQueryPlanner extends QueryPlanner implements Cloneable {
* performance impact.
*/
protected boolean showReducedQueryPrune = true;
/**
* Feature flag to attempt disabling evaluation under certain circumstances when a query contains a grouping function
*/
protected boolean disableGroupByEvaluation = false;

// handles boilerplate operations that surround a visitor's execution (e.g., timers, logging, validating)
private TimedVisitorManager visitorManager = new TimedVisitorManager();
Expand Down Expand Up @@ -3454,4 +3458,12 @@ public int getConcurrentTimeoutMillis() {
public void setConcurrentTimeoutMillis(int concurrentTimeoutMillis) {
this.concurrentTimeoutMillis = concurrentTimeoutMillis;
}

public boolean getDisableGroupByEvaluation() {
return disableGroupByEvaluation;
}

public void setDisableGroupByEvaluation(boolean disableGroupByEvaluation) {
this.disableGroupByEvaluation = disableGroupByEvaluation;
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -488,6 +488,7 @@
<bean id="DefaultQueryPlanner" scope="prototype" class="datawave.query.planner.DefaultQueryPlanner" >
<property name="transformRules" ref="transformRuleList" />
<property name="visitorManager" ref="TimedVisitorManager"/>
<property name="disableGroupByEvaluation" value="true"/>
</bean>

<bean id="TimedVisitorManager" scope="prototype" class="datawave.query.planner.TimedVisitorManager">
Expand Down

0 comments on commit 2cb9dae

Please sign in to comment.