xiedeyantu commented on code in PR #4301:
URL: https://github.com/apache/calcite/pull/4301#discussion_r2041290124


##########
testkit/src/main/java/org/apache/calcite/test/QuidemTest.java:
##########
@@ -171,6 +182,33 @@ protected void checkRun(String path) throws Exception {
               int thresholdValue = ((BigDecimal) value).intValue();
               
closer.add(Prepare.THREAD_INSUBQUERY_THRESHOLD.push(thresholdValue));
             }
+            if (propertyName.equals("rules")) {
+              parseRules((String) value);
+              closer.add(
+                  Hook.PLANNER.addThread((Consumer<RelOptPlanner>)
+                      planner -> {
+                          for (RelOptRule rule : addRulesCache) {
+                            planner.addRule(rule);
+                          }
+                          for (RelOptRule rule : removeRulesCache) {
+                            planner.removeRule(rule);
+                          }
+                      }));
+            }
+            if (propertyName.equals("reset-rules")) {

Review Comment:
   Good catch! I’ll have to give this some more thought.



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

Reply via email to