According to the author, Sasha Pachev, although MySQL source is open in the sense of being publicly available, it is really closed if you do not understand how it works and what it does. It is very intimidating to look at several hundred thousand lines of code written by gifted programmers. But to understand that code will take a measure of the inspiration and perspiration of those who created it.
Let's face facts — on the surface, the concept of a relational database is a simple one, but when you get down to putting the rivets on the plane, there are a lot of them and if you miss some, well you know what happens to planes without all their rivets.
Understanding MySQL Internals is thin in size, but thick in details. It contains twelve chapters and an index. This book is for developers who want to extend MySQL, the DBA who wants to get a better handle on how things run, or the computer science student wanting a better understanding of database kernel development.
Chapter 1, "MySQL History and Architecture," gives an introduction to how the different components of MySQL server work together. By learning the history of MySQL, you will gain a better understanding of its architecture. Chapter 2, "Nuts and Bolts of Working with the MySQL Source Code," will walk you through how to get the software downloaded and then build it from the source. The source is the ultimate documentation.
Chapter 3, "Core Classes, Structures, Variables, and APIs," describes the core server classes by listing the basic data structures, functions, and macros that you will need later in the book. Chapter 4, "Client/Server Communication," explains the communications protocol that is used between the client and the server. Here you will learn how to look at a binary dump of that communication and see what happened.
Chapter 5, "Configuration Variables," discusses the server configuration variables. These are the controls of the server. Each and every one tells you something about some special server capability. This is a good base for the DBA since if you understand the variables, you understand the server.
Chapter 6, "Thread-Based Request Handling," exposes the thread-based handling that goes on in MySQL. By understanding threads, you will become much more effective in handling the server. You will learn the rationale for implementing thread-based request handling.
Chapter 7, "The Storage Engine Interface," focuses on the storage engine interface and how it works within the MySQL Architecture to integrate third party storage engines. This is the mechanism that actually stores and retrieves the data. Here you will learn about the handler class and the handlerton structure.