LearnedWMP:使用查询模板分布的工作负载内存预测
LearnedWMP: Workload Memory Prediction Using Distribution of Query Templates
AI总结:
本文提出LearnedWMP,将工作负载内存预测建模为分布回归,利用查询模板分布并发工作负载内存需求,显著降低估计误差并提升速度、减小模型体积。
摘要:
在现代DBMS中,工作内存通常是处理连接、排序和聚合等内存中分析查询操作时的限制因素。现有的DBMS资源估计方法通过计算查询执行计划中每个独立数据库算子的估计值,来估计查询的资源消耗。这种方法速度慢且容易出错,因为它依赖于简化假设,例如底层数据的均匀性和独立性。此外,现有方法分别关注单个查询,而没有考虑工作负载中可能并发执行的其他查询。在本研究中,我们关注一批查询(即工作负载)并发执行下的查询性能优化。具体而言,我们专注于预测工作负载的内存需求,而不是为其中的每个查询分别提供估计。我们引入了工作负载内存预测问题,并将其形式化为一个分布回归问题。我们提出了Learned Workload Memory Prediction(LearnedWMP,学习型工作负载内存预测),以改进并简化工作负载工作内存需求的估计。通过全面的实验评估,我们表明LearnedWMP将实践中最先进方法的内存估计误差最高降低了47.6%。与另一种单查询模型相比,在训练和推理期间,LearnedWMP模型及其变体的速度快了3倍至10倍。此外,在大多数情况下,基于LearnedWMP的模型体积至少小50%。总体而言,结果证明了LearnedWMP方法的优势及其对查询性能优化产生更广泛影响的潜力。
英文摘要:
In a modern DBMS, working memory is frequently the limiting factor when processing in-memory analytic query operations such as joins, sorting, and aggregation. Existing resource estimation approaches for a DBMS estimate the resource consumption of a query by computing an estimate of each individual database operator in the query execution plan. Such an approach is slow and error-prone as it relies upon simplifying assumptions, such as uniformity and independence of the underlying data. Additionally, the existing approach focuses on individual queries separately and does not factor in other queries in the workload that may be executed concurrently. In this research, we are interested in query performance optimization under concurrent execution of a batch of queries (a workload). Specifically, we focus on predicting the memory demand for a workload rather than providing separate estimates for each query within it. We introduce the problem of workload memory prediction and formalize it as a distribution regression problem. We propose Learned Workload Memory Prediction (LearnedWMP) to improve and simplify estimating the working memory demands of workloads. Through a comprehensive experimental evaluation, we show that LearnedWMP reduces the memory estimation error of the state-of-the-practice method by up to 47.6%. Compared to an alternative single-query model, during training and inferencing, the LearnedWMP model and its variants were 3x to 10x faster. Moreover, LearnedWMP-based models were at least 50% smaller in most cases. Overall, the results demonstrate the advantages of the LearnedWMP approach and its potential for a broader impact on query performance optimization.
机构、总结、中文摘要均由AI分析而来,可能存在错误,请以论文正文为准。