{
    "Plan" : {
        "Plans" : [
            {
                "PlanNodeId" : 6,
                "Plans" : [
                    {
                        "PlanNodeId" : 5,
                        "Plans" : [
                            {
                                "PlanNodeId" : 4,
                                "Plans" : [
                                    {
                                        "PlanNodeId" : 3,
                                        "Plans" : [
                                            {
                                                "PlanNodeId" : 2,
                                                "Plans" : [
                                                    {
                                                        "Tables" : [
                                                            "olap_yatests/clickbench/hits"
                                                        ],
                                                        "PlanNodeId" : 1,
                                                        "Operators" : [
                                                            {
                                                                "Inputs" : [
                                                                    {
                                                                        "InternalOperatorId" : 1
                                                                    }
                                                                ],
                                                                "GroupBy" : "[0,1,2,3,4]",
                                                                "Aggregation" : "",
                                                                "Name" : "Aggregate",
                                                                "Phase" : "Intermediate"
                                                            },
                                                            {
                                                                "Inputs" : [
                                                                    {
                                                                        "InternalOperatorId" : 2
                                                                    }
                                                                ],
                                                                "E-Rows" : "14000",
                                                                "Predicate" : "IsRefresh == 0",
                                                                "Pushdown" : "True",
                                                                "Name" : "Filter",
                                                                "E-Size" : "521986.4229",
                                                                "E-Cost" : "0"
                                                            },
                                                            {
                                                                "Scan" : "Parallel",
                                                                "E-Size" : "5219864.229",
                                                                "ReadRanges" : [
                                                                    "CounterID [62, 62]",
                                                                    "EventDate [15887, 15917]"
                                                                ],
                                                                "Name" : "TableRangeScan",
                                                                "Inputs" : [ ],
                                                                "Path" : "/local/test_db/olap_yatests/clickbench/hits",
                                                                "E-Rows" : "140000",
                                                                "Table" : "olap_yatests/clickbench/hits",
                                                                "ReadRangesKeys" : [
                                                                    "CounterID",
                                                                    "EventDate"
                                                                ],
                                                                "ReadColumns" : [
                                                                    "AdvEngineID",
                                                                    "IsRefresh",
                                                                    "Referer",
                                                                    "SearchEngineID",
                                                                    "TraficSourceID",
                                                                    "URL"
                                                                ],
                                                                "SsaProgram" : {
                                                                    "Command" : [
                                                                        {
                                                                            "Assign" : {
                                                                                "Constant" : {
                                                                                    "Int32" : 0
                                                                                },
                                                                                "Column" : {
                                                                                    "Id" : 106
                                                                                }
                                                                            }
                                                                        },
                                                                        {
                                                                            "Assign" : {
                                                                                "Function" : {
                                                                                    "YqlOperationId" : 11,
                                                                                    "KernelIdx" : 0,
                                                                                    "FunctionType" : 2,
                                                                                    "Arguments" : [
                                                                                        {
                                                                                            "Id" : 16
                                                                                        },
                                                                                        {
                                                                                            "Id" : 106
                                                                                        }
                                                                                    ]
                                                                                },
                                                                                "Column" : {
                                                                                    "Id" : 107
                                                                                }
                                                                            }
                                                                        },
                                                                        {
                                                                            "Filter" : {
                                                                                "Predicate" : {
                                                                                    "Id" : 107
                                                                                }
                                                                            }
                                                                        },
                                                                        {
                                                                            "Projection" : {
                                                                                "Columns" : [
                                                                                    {
                                                                                        "Id" : 41
                                                                                    },
                                                                                    {
                                                                                        "Id" : 15
                                                                                    },
                                                                                    {
                                                                                        "Id" : 39
                                                                                    },
                                                                                    {
                                                                                        "Id" : 38
                                                                                    },
                                                                                    {
                                                                                        "Id" : 14
                                                                                    }
                                                                                ]
                                                                            }
                                                                        }
                                                                    ]
                                                                },
                                                                "E-Cost" : "0",
                                                                "ReadRangesExpectedSize" : 1
                                                            }
                                                        ],
                                                        "Node Type" : "Aggregate-Filter-TableRangeScan",
                                                        "Stats" : {
                                                            "UseLlvm" : "undefined",
                                                            "Output" : [
                                                                {
                                                                    "Pop" : { },
                                                                    "Name" : "3",
                                                                    "Push" : {
                                                                        "WaitTimeUs" : {
                                                                            "Count" : 3,
                                                                            "Sum" : 1346110,
                                                                            "Max" : 450227,
                                                                            "Min" : 447117,
                                                                            "History" : [
                                                                                163,
                                                                                144626,
                                                                                196,
                                                                                520883,
                                                                                280,
                                                                                566818,
                                                                                302,
                                                                                836107,
                                                                                337,
                                                                                960300,
                                                                                361,
                                                                                1013707,
                                                                                412,
                                                                                1045157,
                                                                                413,
                                                                                1098020,
                                                                                435,
                                                                                1203192,
                                                                                436,
                                                                                1242485,
                                                                                444,
                                                                                1266913,
                                                                                447,
                                                                                1293968,
                                                                                448,
                                                                                1319888,
                                                                                452,
                                                                                1326875,
                                                                                454,
                                                                                1346110
                                                                            ]
                                                                        }
                                                                    }
                                                                }
                                                            ],
                                                            "MaxMemoryUsage" : {
                                                                "Count" : 3,
                                                                "Sum" : 9633792,
                                                                "Max" : 3211264,
                                                                "Min" : 3211264,
                                                                "History" : [
                                                                    0,
                                                                    3211264,
                                                                    5,
                                                                    9633792,
                                                                    454,
                                                                    9633792
                                                                ]
                                                            },
                                                            "Tasks" : 3,
                                                            "FinishedTasks" : 3,
                                                            "PhysicalStageId" : 0,
                                                            "StageDurationUs" : 0,
                                                            "Table" : [
                                                                {
                                                                    "Path" : "/local/test_db/olap_yatests/clickbench/hits"
                                                                }
                                                            ],
                                                            "BaseTimeMs" : 1761493826502,
                                                            "CpuTimeUs" : {
                                                                "Count" : 3,
                                                                "Sum" : 8351,
                                                                "Max" : 3425,
                                                                "Min" : 2364,
                                                                "History" : [
                                                                    0,
                                                                    2979,
                                                                    5,
                                                                    7073,
                                                                    163,
                                                                    7125,
                                                                    196,
                                                                    7256,
                                                                    280,
                                                                    7290,
                                                                    302,
                                                                    7451,
                                                                    337,
                                                                    7525,
                                                                    361,
                                                                    7593,
                                                                    412,
                                                                    7623,
                                                                    413,
                                                                    7671,
                                                                    435,
                                                                    7758,
                                                                    444,
                                                                    7789,
                                                                    447,
                                                                    7849,
                                                                    448,
                                                                    7886,
                                                                    452,
                                                                    8021,
                                                                    454,
                                                                    8351
                                                                ]
                                                            },
                                                            "Ingress" : [
                                                                {
                                                                    "Pop" : { },
                                                                    "External" : { },
                                                                    "Name" : "CS",
                                                                    "Ingress" : { },
                                                                    "Push" : { }
                                                                }
                                                            ],
                                                            "UpdateTimeMs" : 454
                                                        }
                                                    }
                                                ],
                                                "HashFunc" : "HashV1",
                                                "Node Type" : "HashShuffle",
                                                "KeyColumns" : [
                                                    "AdvEngineID",
                                                    "Dst",
                                                    "SearchEngineID",
                                                    "Src",
                                                    "TraficSourceID"
                                                ],
                                                "PlanNodeType" : "Connection"
                                            }
                                        ],
                                        "Operators" : [
                                            {
                                                "Inputs" : [
                                                    {
                                                        "ExternalPlanNodeId" : 2
                                                    }
                                                ],
                                                "Name" : "TopSort",
                                                "Limit" : "10",
                                                "TopSortBy" : "argument.Count0"
                                            }
                                        ],
                                        "Node Type" : "TopSort",
                                        "Stats" : {
                                            "UseLlvm" : "undefined",
                                            "DurationUs" : {
                                                "Count" : 1,
                                                "Sum" : 1000,
                                                "Max" : 1000,
                                                "Min" : 1000
                                            },
                                            "Output" : [
                                                {
                                                    "Pop" : { },
                                                    "Name" : "5",
                                                    "Push" : {
                                                        "WaitTimeUs" : {
                                                            "Count" : 2,
                                                            "Sum" : 902751,
                                                            "Max" : 451739,
                                                            "Min" : 451012,
                                                            "History" : [
                                                                452,
                                                                900550,
                                                                454,
                                                                902751
                                                            ]
                                                        }
                                                    }
                                                }
                                            ],
                                            "MaxMemoryUsage" : {
                                                "Count" : 2,
                                                "Sum" : 2228224,
                                                "Max" : 1114112,
                                                "Min" : 1114112,
                                                "History" : [
                                                    5,
                                                    2228224,
                                                    454,
                                                    2228224
                                                ]
                                            },
                                            "Tasks" : 2,
                                            "FinishedTasks" : 2,
                                            "PhysicalStageId" : 1,
                                            "StageDurationUs" : 1000,
                                            "BaseTimeMs" : 1761493826502,
                                            "CpuTimeUs" : {
                                                "Count" : 2,
                                                "Sum" : 1864,
                                                "Max" : 1325,
                                                "Min" : 539,
                                                "History" : [
                                                    5,
                                                    1739,
                                                    452,
                                                    1795,
                                                    454,
                                                    1864
                                                ]
                                            },
                                            "UpdateTimeMs" : 454,
                                            "Input" : [
                                                {
                                                    "Pop" : { },
                                                    "Name" : "1",
                                                    "Push" : {
                                                        "WaitTimeUs" : {
                                                            "Count" : 2,
                                                            "Sum" : 902072,
                                                            "Max" : 451430,
                                                            "Min" : 450642,
                                                            "History" : [
                                                                452,
                                                                900608,
                                                                454,
                                                                902072
                                                            ]
                                                        }
                                                    }
                                                }
                                            ]
                                        }
                                    }
                                ],
                                "Node Type" : "Merge",
                                "SortColumns" : [
                                    "Count0 (Desc)"
                                ],
                                "PlanNodeType" : "Connection"
                            }
                        ],
                        "Operators" : [
                            {
                                "Inputs" : [
                                    {
                                        "ExternalPlanNodeId" : 4
                                    }
                                ],
                                "Name" : "Limit",
                                "Limit" : "10"
                            }
                        ],
                        "Node Type" : "Limit",
                        "Stats" : {
                            "UseLlvm" : "undefined",
                            "Output" : [
                                {
                                    "Pop" : { },
                                    "Name" : "RESULT",
                                    "Push" : {
                                        "WaitTimeUs" : {
                                            "Count" : 1,
                                            "Sum" : 450770,
                                            "Max" : 450770,
                                            "Min" : 450770,
                                            "History" : [
                                                454,
                                                450770
                                            ]
                                        }
                                    }
                                }
                            ],
                            "MaxMemoryUsage" : {
                                "Count" : 1,
                                "Sum" : 65536,
                                "Max" : 65536,
                                "Min" : 65536,
                                "History" : [
                                    5,
                                    65536,
                                    454,
                                    65536
                                ]
                            },
                            "Tasks" : 1,
                            "FinishedTasks" : 1,
                            "PhysicalStageId" : 2,
                            "StageDurationUs" : 0,
                            "BaseTimeMs" : 1761493826502,
                            "CpuTimeUs" : {
                                "Count" : 1,
                                "Sum" : 585,
                                "Max" : 585,
                                "Min" : 585,
                                "History" : [
                                    5,
                                    559,
                                    454,
                                    585
                                ]
                            },
                            "UpdateTimeMs" : 454,
                            "Input" : [
                                {
                                    "Pop" : { },
                                    "Name" : "3",
                                    "Push" : {
                                        "WaitTimeUs" : {
                                            "Count" : 1,
                                            "Sum" : 225392,
                                            "Max" : 225392,
                                            "Min" : 225392,
                                            "History" : [
                                                454,
                                                225392
                                            ]
                                        }
                                    }
                                }
                            ]
                        }
                    }
                ],
                "Node Type" : "ResultSet_1",
                "PlanNodeType" : "ResultSet"
            }
        ],
        "Node Type" : "Query",
        "Stats" : {
            "Compilation" : {
                "FromCache" : false,
                "DurationUs" : 2066408,
                "CpuTimeUs" : 2052355
            },
            "ProcessCpuTimeUs" : 1474,
            "TotalDurationUs" : 2554917,
            "ResourcePoolId" : "default",
            "QueuedTimeUs" : 0
        },
        "PlanNodeType" : "Query"
    },
    "meta" : {
        "version" : "0.2",
        "type" : "query"
    },
    "SimplifiedPlan" : {
        "PlanNodeId" : 0,
        "Plans" : [
            {
                "PlanNodeId" : 1,
                "Plans" : [
                    {
                        "PlanNodeId" : 2,
                        "Plans" : [
                            {
                                "PlanNodeId" : 4,
                                "Plans" : [
                                    {
                                        "PlanNodeId" : 5,
                                        "Plans" : [
                                            {
                                                "PlanNodeId" : 6,
                                                "Plans" : [
                                                    {
                                                        "PlanNodeId" : 7,
                                                        "Plans" : [
                                                            {
                                                                "PlanNodeId" : 8,
                                                                "Operators" : [
                                                                    {
                                                                        "Scan" : "Parallel",
                                                                        "E-Size" : "5219864.229",
                                                                        "ReadRanges" : [
                                                                            "CounterID [62, 62]",
                                                                            "EventDate [15887, 15917]"
                                                                        ],
                                                                        "Name" : "TableRangeScan",
                                                                        "Path" : "/local/test_db/olap_yatests/clickbench/hits",
                                                                        "E-Rows" : "140000",
                                                                        "Table" : "olap_yatests/clickbench/hits",
                                                                        "ReadRangesKeys" : [
                                                                            "CounterID",
                                                                            "EventDate"
                                                                        ],
                                                                        "ReadColumns" : [
                                                                            "AdvEngineID",
                                                                            "IsRefresh",
                                                                            "Referer",
                                                                            "SearchEngineID",
                                                                            "TraficSourceID",
                                                                            "URL"
                                                                        ],
                                                                        "SsaProgram" : {
                                                                            "Command" : [
                                                                                {
                                                                                    "Assign" : {
                                                                                        "Constant" : {
                                                                                            "Int32" : 0
                                                                                        },
                                                                                        "Column" : {
                                                                                            "Id" : 106
                                                                                        }
                                                                                    }
                                                                                },
                                                                                {
                                                                                    "Assign" : {
                                                                                        "Function" : {
                                                                                            "YqlOperationId" : 11,
                                                                                            "KernelIdx" : 0,
                                                                                            "FunctionType" : 2,
                                                                                            "Arguments" : [
                                                                                                {
                                                                                                    "Id" : 16
                                                                                                },
                                                                                                {
                                                                                                    "Id" : 106
                                                                                                }
                                                                                            ]
                                                                                        },
                                                                                        "Column" : {
                                                                                            "Id" : 107
                                                                                        }
                                                                                    }
                                                                                },
                                                                                {
                                                                                    "Filter" : {
                                                                                        "Predicate" : {
                                                                                            "Id" : 107
                                                                                        }
                                                                                    }
                                                                                },
                                                                                {
                                                                                    "Projection" : {
                                                                                        "Columns" : [
                                                                                            {
                                                                                                "Id" : 41
                                                                                            },
                                                                                            {
                                                                                                "Id" : 15
                                                                                            },
                                                                                            {
                                                                                                "Id" : 39
                                                                                            },
                                                                                            {
                                                                                                "Id" : 38
                                                                                            },
                                                                                            {
                                                                                                "Id" : 14
                                                                                            }
                                                                                        ]
                                                                                    }
                                                                                }
                                                                            ]
                                                                        },
                                                                        "E-Cost" : "0",
                                                                        "ReadRangesExpectedSize" : 1
                                                                    }
                                                                ],
                                                                "Node Type" : "TableRangeScan"
                                                            }
                                                        ],
                                                        "Operators" : [
                                                            {
                                                                "E-Rows" : "14000",
                                                                "Predicate" : "IsRefresh == 0",
                                                                "Pushdown" : "True",
                                                                "Name" : "Filter",
                                                                "E-Size" : "521986.4229",
                                                                "E-Cost" : "0"
                                                            }
                                                        ],
                                                        "Node Type" : "Filter"
                                                    }
                                                ],
                                                "Operators" : [
                                                    {
                                                        "GroupBy" : "[0,1,2,3,4]",
                                                        "A-SelfCpu" : 3.425,
                                                        "Aggregation" : "",
                                                        "A-Cpu" : 3.425,
                                                        "Name" : "Aggregate",
                                                        "Phase" : "Intermediate"
                                                    }
                                                ],
                                                "Node Type" : "Aggregate"
                                            }
                                        ],
                                        "Node Type" : "HashShuffle (KeyColumns: [\"AdvEngineID\",\"Dst\",\"SearchEngineID\",\"Src\",\"TraficSourceID\"], HashFunc: \"HashV1\")",
                                        "PlanNodeType" : "Connection"
                                    }
                                ],
                                "Operators" : [
                                    {
                                        "A-SelfCpu" : 1.325,
                                        "A-Cpu" : 4.75,
                                        "Name" : "TopSort",
                                        "Limit" : "10",
                                        "TopSortBy" : "argument.Count0"
                                    }
                                ],
                                "Node Type" : "TopSort"
                            }
                        ],
                        "Operators" : [
                            {
                                "A-SelfCpu" : 0.585,
                                "A-Cpu" : 5.335,
                                "Name" : "Limit",
                                "Limit" : "10"
                            }
                        ],
                        "Node Type" : "Limit"
                    }
                ],
                "Node Type" : "ResultSet_1",
                "PlanNodeType" : "ResultSet"
            }
        ],
        "Node Type" : "Query",
        "PlanNodeType" : "Query"
    }
}
