Memcached vs Redis

A very dynamic web applications, of course, will slow down the performance of the web itself. As more and more definite dynamic data that will be loaded from the database will certainly be a lot. To get around the database load too much we can use memcache and also the Redis. Each of them surely has the edge among us. But, who is the most widely chosen by many people? If Memcache or Redis? As long as you guys are reading this website, you will find out the real answer.

Memcached
The use of Memcached now used by several companies to support large data load. Memcached is memory-object-caching-system, public nature, intended for use in speeding up dynamic web applications by easing the burden of database. Memcached works as some sort of hash or array of associations that can store data in the form of a string, integer or even object. This hash data stored in computer memory (RAM) to the very fast to access. The concept of distributing data with conventional methods of the database without using memcache there are five types of Data, namely the request from a client, the Server database, the Database loaded accesing the data to the server, and the Data sent to the client. Please note in advance that the hash function to be an identity or some sort of a fingerprint data, a hash can be implemented for data regardless of its length and produces a fixed length or size.

Redis
Redis is an open source, the structure of the data placed in memory, is used as the database, cache and message broker. Redis supports data structures such as a string, hash, sets, lists and sorted sets. Same as cache, each key is filled by value. But the benefits, Redis can be used to perform the operation from the value. The best way to understand the application of Redis is a model without thinking how to save data in the database. Redis is a data structure on the server. This is certainly making it slower than simply storing the data in local memory. But the Redis also has some interesting things, such as storage in memory by Redis very efficiently and done in a separate process. If the application is running on a platform or programming language that would be wasteful of memory, Redis allows handling memory allocation that is much larger. (Read also : MongoDB vs Redis)

MemcachedRedis
- A cache or indexing server- A cache server and data server as well
- The examples is used by detik.com- Redis itself much used by Ruby on Rails programmer. For PHP programmers, redis is still somewhat layman
- The workings of memcached is simple because it only function cache server and reduce load to the database server- Could replace mysql server database and storing in the memory and file

Memcached vs Redis
It is based on what you really need and before you decide an option, we give you two choices. Memcached is used when we need to cache only server or we want to keep the php session so that the php server we can in the cluster. Redis is used when we want to cache and the database server is a fast and powerful. Because both memory, memory-based server we use should be pretty strong and not be able to run on shared hosting.

Leave a Reply