Network Security Internet Technology Development Database Servers Mobile Phone Android Software Apple Software Computer Software News IT Information

In addition to Weibo, there is also WeChat

Please pay attention

WeChat public account

Shulou

What is the three-tier logical architecture of MySQL?

2025-04-03 Update From: SLTechnology News&Howtos shulou NAV: SLTechnology News&Howtos > Development >

Share

Shulou(Shulou.com)06/01 Report--

Editor to share with you what the three-tier logical structure of MySQL is, I believe most people do not know much about it, so share this article for your reference, I hope you can learn a lot after reading this article, let's go to know it!

MySQL three-tier logical architecture

MySQL's storage engine architecture separates query processing from data storage / extraction. The following is a logical architecture diagram of MySQL:

1. The first layer is responsible for connection management, authorization authentication, security and so on.

Each client's connection corresponds to a thread on the server. A thread pool is maintained on the server to avoid creating and destroying one thread for each connection. When the client connects to the MySQL server, the server authenticates it. It can be authenticated by user name and password, or by SSL certificate. After the login authentication is passed, the server also verifies that the client has permission to execute a query.

2. The second layer is responsible for parsing the query

Compile the SQL and optimize it (such as adjusting the reading order of the table, selecting the appropriate index, etc.). For SELECT statements, the server will check the query cache before parsing the query. If the corresponding query results can be found in it, the query results will be returned directly without the need for query parsing, optimization and other processes. Stored procedures, triggers, views, and so on are all implemented at this layer.

3. The third layer is the storage engine

The storage engine is responsible for storing data in MySQL, extracting data, opening a transaction, and so on. The storage engine communicates with the upper layer through API. These API shield the differences between different storage engines and make these differences transparent to the upper layer query process. The storage engine does not parse SQL.

The above is all the content of the article "what is the three-tier logical architecture of MySQL". Thank you for reading! I believe we all have a certain understanding, hope to share the content to help you, if you want to learn more knowledge, welcome to follow the industry information channel!

Welcome to subscribe "Shulou Technology Information " to get latest news, interesting things and hot topics in the IT industry, and controls the hottest and latest Internet news, technology news and IT industry trends.

Views: 292

*The comments in the above article only represent the author's personal views and do not represent the views and positions of this website. If you have more insights, please feel free to contribute and share.

Share To

Development

Wechat

© 2024 shulou.com SLNews company. All rights reserved.

12
Report