具有嵌套 summarize/join 的 Kusto 洗牌策略行为
Kusto shuffle strategy behavior with nested summarize/join
在提高 Kusto 查询的性能时,我遇到了 join/summarize 的随机播放策略。我可以清楚地看到这种策略对我的查询的性能优势,它对 join/summarize 键具有高基数。
在阅读shuffle query Kusto documentation时,似乎当有嵌套的洗牌运算符时,该策略将被忽略。
When the shuffled operator has other shuffle-able operators, like summarize or join, the query becomes more complex and then hint.strategy=shuffle won't be applied.
我的查询使用嵌套汇总和连接(带随机播放),但我也清楚地看到了性能提升。我的查询模式:
Table1
| summarize hint.strategy=shuffle arg_max(Timestamp) by Device, Interface
| join hint.strategy=shuffle (Table2) on Device, Interface
这样的查询是否受益于改组?
此外,如果 Kusto 查询规划器始终存在,是否会避免任何有问题的混洗?基本上我想放心,可能只有错误 used/authored 洗牌的性能问题,而不是数据问题。
请注意,随机查询文章建议使用 hint.shufflekey 以防嵌套 summarize/join 运算符,但它要求嵌套的 summarize/join 运算符具有相同的 group-by/join键。
所以在上面的示例中,应用以下内容(我假设 Device 具有高基数(并且您可以 remove/keep 总结中的随机播放策略,keeping/removing 它将是只要您在包含此摘要的连接上指定随机播放键,行为相同):
表1
|按设备、接口汇总 arg_max(Timestamp)
|在设备上加入 hint.shufflekey=设备 (Table2),接口
在提高 Kusto 查询的性能时,我遇到了 join/summarize 的随机播放策略。我可以清楚地看到这种策略对我的查询的性能优势,它对 join/summarize 键具有高基数。
在阅读shuffle query Kusto documentation时,似乎当有嵌套的洗牌运算符时,该策略将被忽略。
When the shuffled operator has other shuffle-able operators, like summarize or join, the query becomes more complex and then hint.strategy=shuffle won't be applied.
我的查询使用嵌套汇总和连接(带随机播放),但我也清楚地看到了性能提升。我的查询模式:
Table1
| summarize hint.strategy=shuffle arg_max(Timestamp) by Device, Interface
| join hint.strategy=shuffle (Table2) on Device, Interface
这样的查询是否受益于改组?
此外,如果 Kusto 查询规划器始终存在,是否会避免任何有问题的混洗?基本上我想放心,可能只有错误 used/authored 洗牌的性能问题,而不是数据问题。
请注意,随机查询文章建议使用 hint.shufflekey 以防嵌套 summarize/join 运算符,但它要求嵌套的 summarize/join 运算符具有相同的 group-by/join键。
所以在上面的示例中,应用以下内容(我假设 Device 具有高基数(并且您可以 remove/keep 总结中的随机播放策略,keeping/removing 它将是只要您在包含此摘要的连接上指定随机播放键,行为相同):
表1 |按设备、接口汇总 arg_max(Timestamp) |在设备上加入 hint.shufflekey=设备 (Table2),接口