Book Review: Expert PHP and MySQL

This post was originally published in 2010
The tips and techniques explained may be outdated.

Expert PHP and MySQL coverHi!
For my birthday, I got the new book from Wrox – Expert PHP and MySQL byAndrew Curioso, Ronald Bradford and Patrick Galbraith.
“This book examines some of the technologies and techniques needed to make robust and scalable applications perform in today’s high-demand world” – this excerpt was taken from the introduction section of the book.

In this book you can learn about the following:

  • Advanced MySQL concepts (Stored Procedures, different drivers and Storage Engines, Views, Triggers and Replications)
  • PHP Opcode Cache with APC or eAccelerator
  • PHP Caching techniques – Memcached
  • Multi-tasking in PHP and MySQL with Gearman
  • More…

This book is for developers who’ve worked on several projects and have some solid experience developing with PHP and MySQL.  Also, developers who have created high-demand applications or applications that handle a lot of data and processing. OOP experience is recommended.
What I really enjoyed in this book is the following:

  • Gearman – provides a generic application framework to farm out work to other machines or processes that are better suited to do the work. Also, it allows you to do work in parallel to reduce the load on your client server (which makes your application respond faster).
  • Memcached – Memcached are “high-performance distributed memory objects [with a] caching system.” It provides key=>value cache for your applications to reduce the load on your database.  In other words, it uses the free memory in your server and caches objects of your application. It is really simple to work with Memcached and has many performance benefits.
  • APC/eAccelerator – Each time you run the php script, the PHP compiler compiles your code over and over again. In the production environment, the code isn’t changing very much. APC and eAccelerator (which are different tools) allow you to cache the compiled code.   That way, the server isn’t compiling the same code over and over again and you get a much better performance. In PHP6, you will have the APC extension natively.

The techniques discussed in this book are used by large sites we are familiar with, such as Digg, Yahoo, Facebook, YouTube and more.  If it is good for those sites, it is probably good for you too.

Related Posts

Tags: Book Review, PHP

  • Pingback: Expert PHP and MySQL | Andrew's Tech Musings

  • http://www.laptopbatteriesinc.com.au laptop battery

    in uses the free memory in your server and uses this to cache objects of your application. its really simple to work with Memcached and it has lots of performance benefits.

WordPress SEO fine-tune by Meta SEO Pack from Poradnik Webmastera