Font Size: a A A

Optimization And Implementation Of Query Method In Distributed Relational Database

Posted on:2022-03-09Degree:MasterType:Thesis
Country:ChinaCandidate:J YangFull Text:PDF
GTID:2518306524480534Subject:Computer Science and Technology
Abstract/Summary:PDF Full Text Request
The ever-evolving information age has brought about an explosive growth in data,which has catalyzed the evolution of technologies in the database field.From traditional relational databases to the burgeoning New SQL databases,from stand-alone databases to distributed databases,evolving database technologies aim to solve two fundamental problems: how to efficiently organise and store data,and how to quickly query and process data.The query optimizer has been the focus of scientific research and engineering imple-mentation in the database field as a key component affecting the efficiency of database queries for fast query processing of data.However,there are still some problems with query optimizer in both the logical and physical optimization phases.In logical optimiza-tion,query optimizer remain at the heuristic stage for relational algebra,lacking sensitivity and flexibility to query statements.In physical optimization,the complex database de-ployment environment and variable data distribution make it difficult for the optimizer's existing base estimation scheme to adapt to changes in the current data state and decide on a more reasonable execution plan.To address these issues,the thesis is based on the Volcano query optimizer model and a specific implementation of Ti DB,a distributed relational database,to carry out re-search on logical and physical optimization.In the logical optimization stage,an adaptive logic optimization rule matching method based on reinforcement learning is proposed.The method uses a tree convolutional neural network to extract logical plan trees and op-timizer state information features,and uses a reinforcement learning model to obtain the matching order of application of optimization rules,so that the optimizer can select the optimization rules suitable for the current query and improve its ability to sense the query statements.In the physical optimization stage,a base estimation scheme based on sample statistical information is designed to improve the accuracy of base estimation by quickly collecting samples from the raw database data as a supplement to the statistical informa-tion to participate in the query optimizer base estimation process.Finally,the proposed logical optimization method and physical optimization scheme are implemented based on the Ti DB SQL engine.The test results show that in logical op-timization,the reinforcement learning-based adaptive logical optimization rule matching approach can improve the flexibility and scalability of the optimizer.In physical opti-mization,the base estimation scheme based on sample statistics can improve the base estimation accuracy of the native database system,thus improving the query execution efficiency of the database.
Keywords/Search Tags:Logical Optimization, Physical Optimization, Cardinality Estimation, Reinforcement Learning, TiDB
PDF Full Text Request
Related items