Ever noticed that certain things on a Facebook page load faster than others? This is often the case with even the simplest of websites, but with a site the size of Facebook’s globe-spanning social network, the divide is in some ways more pronounced. Facebook, you see, serves information from two very different collections of data.
Most data is stored inside a good old fashioned database — the open source mainstay MySQL — but the social networking giant also uses a second system to house data that’s accessed with particular frequency. This system is known as Memcached, and it’s a common thing inside the massive data centers that underpin the world’s largest websites. Memcached stores data in the memory subsystems of the servers that drive Facebook, rather than slower hard disks. Facebook engineers call it “hot data.” Basically, this means that the data you’re more likely to visit is more likely to load at speed.
The rub is that juggling both MySQL and Memcached isn’t the easiest of tasks for the engineers that build and operate the Facebook machine. But in recent years, the company has built a new system that seeks to ease the use of these two data stores. It’s called TAO, short for “The Associations and Objects,” and it’s been used on the site for “several” years now.