Understanding MySQL Internals

Reviewed by Major Keary

MySQL InternalsThis is a valuable companion text to High Performance MySQL, also published by O'Reilly.

The author of MySQL Internals, Sasha Pachev, was a member of the MySQL development team and the original developer of replication in MySQL. The book was written when MySQL 5.0 was the stable version and 5.1 was in beta, so—even though published in 2007—it is still relevant. In the preface the author says, "Fortunately, most of the code tends to remain intact, so the book has a shot at not becoming obsolete before it is published".

Mentioned in the Who This Book is For section are "developers trying to extend MySQL in some way", DBA or database application programmers interested in how MySQL queries are run, computer science students, anyone curious about what is inside MySQL, and those "who want to look smart by having a book on MySQL internals" on their bookshelf.

MySQL Internals contains information that won't be found in many other MySQL books. For example, instructions on how one finds things in the source, and coding guidelines for those who want to modify the source. The text is supported by extensive code examples.

There is a remarkably extensive collection of detailed tables that should be a valuable look-up resource in their own right. A random selection indicates their scope:

  • Versions maintained by BitKeeper (lists repositories up to development version 5.2)
  • Top-level directories in MySQL source tree
  • Client commands
  • Common gbd commands
  • Members of the .NET class
  • Members of the handlerton structure
  • Handler methods
  • Global variables related to threads.

Chapter headings indicate the book's scope:

  • MySQL History & Architecture
  • Nuts & Bolts of Working with the MySQL Source Code
  • Core Classes, Structures, Variables, and APIs
  • Client/Server Communication
  • Configurable Variables
  • Thread-Based Request Handling
  • The Storage Engine Interface
  • Concurrent Access & Locking
  • Parser Optimizer
  • Storage Engines
  • Transactions
  • Replication

The author has packed a surprising amount of material into a small space (just over 200 pages) without sacrificing readability. The book is not the kind of thing one might read on the bus, or browse; it is a tool to be used for "discovering and improving a great database" (the book's sub-title). It deserves a place in any library with holdings on database technology, and should be considered for computer science reading lists.

Sasha Pachev: Understanding MySQL Internals
ISBN 978-0-596-00957-1
Published by O'Reilly, 234 pp., RRP AU$ 105.00

O'Reilly books are distributed in Australia by Woodslane www.woodslane.com.au


Post new comment

The content of this field is kept private and will not be shown publicly.
  • Allowed HTML tags: <a> <b> <dd> <dl> <dt> <i> <img> <li> <ol> <u> <ul> <pre> <br> <blockquote> <hr> <code><sup><sup><p><em><strong> <h2> <cite> <code> <tt> <h1><table><tr><th><td>
  • Lines and paragraphs break automatically.

More information about formatting options

This question is for testing whether you are a human visitor and to prevent automated spam submissions.
10 + 9 =
Solve this simple math problem and enter the result. E.g. for 1+3, enter 4.