You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@calcite.apache.org by "Xiening Dai (Jira)" <ji...@apache.org> on 2020/04/11 01:12:00 UTC

[jira] [Issue Comment Deleted] (CALCITE-3915) Add rule listener to report rule attempts and time at DEBUG log level

     [ https://issues.apache.org/jira/browse/CALCITE-3915?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Xiening Dai updated CALCITE-3915:
---------------------------------
    Comment: was deleted

(was: The example in the description is messed up due to the indents. We will have a pretty output in console.)

> Add rule listener to report rule attempts and time at DEBUG log level
> ---------------------------------------------------------------------
>
>                 Key: CALCITE-3915
>                 URL: https://issues.apache.org/jira/browse/CALCITE-3915
>             Project: Calcite
>          Issue Type: Bug
>            Reporter: Xiening Dai
>            Priority: Minor
>
> We can add a rule listener to the VolcanoPlanner for recording rule attempts and the accumulative time for the rule firing. This would be very helpful to debug planner performance issue (such as CALCITE-2970). The listener will only be added under DEBUG log level.
> It will produce a rule attempt summary like below -
> {noformat}
> 2020-04-10 18:03:24,621 [main] DEBUG - 
> Rules                                                                   Attempts           Time (us)
> ProjectMergeRule:force_mode                                                1,203           1,124,242
> EnumerableProjectRule(in:NONE,out:ENUMERABLE)                                129             226,475
> AggregatePullUpConstantsRule                                                  84               1,949
> AggregateProjectMergeRule                                                     81             128,575
> ProjectFilterTransposeRule                                                    76               8,734
> JoinPushExpressionsRule                                                       71              10,314
> FilterJoinRule:FilterJoinRule:no-filter                                       71               1,306
> JoinPushThroughJoinRule:right                                                 47                 676
> JoinPushThroughJoinRule:left                                                  45             175,696
> FilterJoinRule:FilterJoinRule:filter                                          41              89,381
> ReduceExpressionsRule(Filter)                                                 24              38,128
> EnumerableFilterRule(in:NONE,out:ENUMERABLE)                                  24              52,457
> EnumerableJoinRule(in:NONE,out:ENUMERABLE)                                    24              71,752
> EnumerableMergeJoinRule(in:NONE,out:ENUMERABLE)                               24              47,987
> FilterProjectTransposeRule                                                    22              55,177
> JoinCommuteRule                                                               20              70,240
> EnumerableAggregateRule(in:NONE,out:ENUMERABLE)                               10              26,522
> AggregateExpandDistinctAggregatesRule                                         10                  37
> EnumerableTableScanRule(in:NONE,out:ENUMERABLE)                                1                 527
> EnumerableInterpreterRule(in:BINDABLE,out:ENUMERABLE)                          1                 764
> BindableTableScanRule                                                          1               1,710
> ExpandConversionRule                                                           1                 175
> {noformat}



--
This message was sent by Atlassian Jira
(v8.3.4#803005)