Balsa: Learning a Query Optimizer Without Expert Demonstrations

01/05/2022
by   Zongheng Yang, et al.
13

Query optimizers are a performance-critical component in every database system. Due to their complexity, optimizers take experts months to write and years to refine. In this work, we demonstrate for the first time that learning to optimize queries without learning from an expert optimizer is both possible and efficient. We present Balsa, a query optimizer built by deep reinforcement learning. Balsa first learns basic knowledge from a simple, environment-agnostic simulator, followed by safe learning in real execution. On the Join Order Benchmark, Balsa matches the performance of two expert query optimizers, both open-source and commercial, with two hours of learning, and outperforms them by up to 2.8× in workload runtime after a few more hours. Balsa thus opens the possibility of automatically learning to optimize in future compute environments where expert-designed optimizers do not exist.

READ FULL TEXT

page 1

page 2

page 3

page 4

research
02/28/2018

Deep Reinforcement Learning for Join Order Enumeration

Join order selection plays a significant role in query performance. Many...
research
01/07/2019

Guided Automated Learning for query workload re-Optimization

Query optimization is a hallmark of database systems enabling complex SQ...
research
09/26/2018

Towards a Hands-Free Query Optimizer through Deep Learning

Query optimization remains one of the most important and well-studied pr...
research
04/07/2019

Neo: A Learned Query Optimizer

Query optimization is one of the most challenging problems in database s...
research
11/26/2019

Join Query Optimization with Deep Reinforcement Learning Algorithms

Join query optimization is a complex task and is central to the performa...
research
12/18/2020

Query Answering via Decentralized Search

Expert networks are formed by a group of expert-professionals with diffe...
research
08/09/2018

Learning to Optimize Join Queries With Deep Reinforcement Learning

Exhaustive enumeration of all possible join orders is often avoided, and...

Please sign up or login with your details

Forgot password? Click here to reset