go back
go back
Volume 18, No. 3
Laser: Buffer-Aware Learned Query Scheduling in Master-Standby Databases
Abstract
Master-standby database deployment is a commonly adopted data-Master-standby database deployment is a commonly adopted database architecture in modern production environments, thanks to its fault tolerance and high availability. However, despite the architec-fault tolerance and high availability. However, despite the architecture’s widespread application in various online services, relatively few research efforts have been made to improve its overall query performance. When a sequence of queries arrive, existing methods of scheduling them across master and standby servers still rely on rules or heuristics, which may overlook some potential opti-on rules or heuristics, which may overlook some potential optimization directions such as buffer utilization. If we can efficiently reuse the database buffers resident in memory through intelligent query scheduling, the average response time of user queries can be significantly reduced as opposed to reading data from disk. To address this issue, in this paper, we introduce a new buffer-To address this issue, in this paper, we introduce a new bufferaware query scheduling system named Laser . The system integrates a lightweight learned model that can directly map a query to the data blocks it accesses. Then, based on the predictions of the queries, we develop adaptive query scheduling algorithms to perform query allocation as well as query rearrangements, aiming to maximize the overall buffer hit rate while also maintaining load balance. The proposed system requires no pre-training, and can adjust to unseen workloads on the fly through constant model updates and query re-allocation. In our experiments, we observe a reduction of ∼ 80% in query completion time compared to other traditional heuristic-in query completion time compared to other traditional heuristicbased methods, with relatively low extra overhead added to the critical path of query execution.
PVLDB is part of the VLDB Endowment Inc.
Privacy Policy