Database systems encompass several performance-critical optimization tasks, such as join ordering and index tuning. As data volumes grow and workloads become more complex, these problems have become exponentially harder to solve efficiently. Quantum computing, especially quantum annealing, is a promising paradigm that can efficiently explore very large search spaces through quantum tunneling. It can escape local optima by tunneling through energy barriers rather than climbing over them. Earlier works mainly focused on providing an abstract representation (e.g., Quadratic Unconstrained Binary Optimization (QUBO)) for the database optimization problems (e.g., join order) and overlooked the real integration within database systems due to the high overhead of quantum computing services (e.g., a minimum 5s runtime for D-Wave's CQM-Solver). Recently, quantum annealing providers have offered more low-latency solutions, e.g., NL-Solver, which paves the road to actually realizing quantum solutions within DBMSs. However, this raises new systems research challenges in balancing efficiency and solution quality. In this talk, we show that this balance is possible to achieve. As a proof of concept, we present Q2O, the first real Quantum-augmented Query Optimizer. We show the end-to-end workflow: we encode the join order problem as a nonlinear model, a format solvable by the NL-Solver, using actual database statistics; the solution is translated into a plan hint that guides PostgreSQL's optimizer to produce a complete plan. Q2O is capable of handling actual queries in real time.
翻译:数据库系统包含多项性能关键型优化任务,如连接顺序优化与索引调优。随着数据量的增长与工作负载日益复杂,此类问题的求解难度呈指数级上升。量子计算,特别是量子退火,是一种前景广阔的计算范式,能够通过量子隧穿效应高效探索庞大的搜索空间。它能够通过穿越而非翻越能量势垒的方式逃离局部最优解。早期研究主要聚焦于为数据库优化问题(如连接顺序)提供抽象表示(例如二次无约束二进制优化模型),但由于量子计算服务的高昂开销(如D-Wave的CQM-Solver至少需要5秒运行时间),未能真正实现与数据库系统的实际集成。近期,量子退火服务商已提供更低延迟的解决方案(如NL-Solver),这为在数据库管理系统中实际部署量子解决方案铺平了道路。然而,这引发了平衡效率与求解质量的系统性研究新挑战。本报告将论证这种平衡是可实现的。作为概念验证,我们提出了首个量子增强型查询优化器Q2O。我们展示了端到端工作流程:基于实际数据库统计信息,将连接顺序问题编码为非线性模型(该格式可由NL-Solver求解);将求解结果转化为计划提示,以指导PostgreSQL优化器生成完整执行计划。Q2O能够实时处理实际查询。