What's memcache?
Memcache is a danga.com project, the first to serve the LiveJournal, many people around the world use this cache project to build their own heavy load of the site to share the pressure of the database.
It can handle any number of connections and use non-blocking network IO. Because its working mechanism is to open up a space in memory, and then establish a hashtable,memcached self management of these hashtable.
Memcache Official website: http://www.danga.com/memcached, more detailed information can come here to understand:)
Why are there memcache and memcached two kinds of names?
In fact Memcache is the name of this project, and memcached is its server-side main program file name, know what I mean put ~ ~ ~ ~ ~ One is the project name, one is the main program file name, on the internet to see a lot of people do not understand, so mixed use.
The Memcache module provides a convenient process-oriented and object-oriented interface for memcached, memcached a resident process caching product that results from loading data from a database for dynamic Web applications. The Memcache module also provides a session processor (Memcache). The following PHP programmer Rechesson A detailed explanation of the PHP operation Memcache Basic functions.
Memcache-memcache class
memcache::add-Add an entry to the cache server
memcache::addserver-Add a Memcache server to the connection pool
memcache::close-Close Memcache Connection
memcache::connect-Open a memcached service-side Connection
Memcache::d ecrement-to reduce key value
Memcache::d elete-Remove a key from the server
memcache::flush-Clean (delete) All keys that have been stored
memcache::get-Check back a key from the service side
memcache::getextendedstats-all server statistics in the cache server pool
Memcache::getserverstatus-is used to get the online/offline status of a server
memcache::getstats-Get Server statistics
memcache::getversion-Return Server version information
memcache::increment-Add the value of a key
Memcache::p connect-to open a persistent connection to the server
Memcache::replace-replaces the value of a key that already exists
memcache::set-store value, no new key is added, existing key is replaced directly
Memcache::setcompressthreshold-Open Large Value automatic compression
memcache::setserverparams-Modify server parameters and status at runtime
Memcache function memcache_debug-conversion debug output on/off
The above is a small set to introduce the PHP operation Memcache Basic functions, I hope to help you, if you have any questions please give me a message, small series will promptly reply to everyone. Here also thank you very much for the cloud Habitat Community website support!