Memcached Tutorial

Memcached is a free and open-source, high-performance, distributed in-memory object caching system.

Memcached is software developed under the leadership of Brad Fitzpatric of Danga Interactive, a subsidiary of LiveJournal. It has now become an important factor in improving the scalability of Web applications in many services such as mixi, hatena, Facebook, Vox, LiveJournal, and more.

Memcached is a memory-based key-value store used to store small chunks of arbitrary data (strings, objects). This data can be the result of database calls, API calls, or page rendering.

Memcached is simple yet powerful. Its simple design facilitates rapid development, reduces development difficulty, and solves many problems with caching large volumes of data. Its API is compatible with most popular development languages.

In essence, it is a simple key-value storage system.

The general purpose is to reduce the number of database accesses by caching database query results, thereby increasing the speed and scalability of dynamic Web applications.

Memcached official website:https://memcached.org/。


Features

As a high-speed distributed cache server, memcached has the following characteristics.

  • Simple protocol
  • Event handling based on libevent
  • Built-in memory storage method
  • Distributed with memcached servers not communicating with each other

Supported Languages

Many languages have implemented clients for connecting to memcached, mainly Perl and PHP. Just to name a few listed on the memcached website:

  • Perl
  • PHP
  • Python
  • Ruby
  • C#
  • C/C++
  • Lua
  • etc.

Memcached Users

  • LiveJournal
  • Wikipedia
  • Flickr
  • Bebo
  • Twitter
  • Typepad
  • Yellowbot
  • Youtube
  • WordPress.com
  • Craigslist
  • Mixi
Other Extensions