MongoDB is a document-based database where all data is read and written from disk. MongoDB is a good long query for modeless JSON data.
And Redis is a memory-based key-value database, which is implemented by C language, similar to Nginx/nodejs working principle, the same way as a single-threaded asynchronous operation, read and write memory and asynchronous synchronization to disk, read and write speed than MongoDB has a huge increase. Therefore, many ultra-high concurrent websites/applications use Redis as a cache layer, which is generally considered to be significantly better than memorycache. When concurrency reaches a certain level, consider using Redis to cache data and persist the session. Memcached: A single key value to the memory cache, do the object cache no alternative to the distributed cache; Redis: is a collection of algorithms and data structures, the fast data structure operation is his greatest feature, supporting the persistence of the database; MongoDB is a bson structure, between an rdb and a nosql, Looser and more flexible, but does not support transactions and serves only as non-critical data stores. NoSQL not-only SQL refers to the pan-non-relational database Redis and memcache are good caching schemes, each with its own advantages and disadvantages
The strongest place for Redis is the rich data structure, which can play many tricks in the cache layer, such as: Through the list to do the message queue, through the Mget,mset can read multiple values to operate and so on, Sina,instagram are relatively good use of its advantages, A single point problem is not a good solution, need to improve
Memcache's strengths are distributed relatively mature, multi-core CPU applications, Yutube, most e-commerce sites are its users, more mature, stable.
MongoDB as a representative of NoSQL should be a useful complement to traditional databases, it does not seem to replace their status, today's NoSQL domain has many powerful competitors in many ways to deal with the massive data problems. One of the most important solutions is MongoDB. MongoDB is a document-oriented, weakly structured storage scheme that uses JSON format to visualize, query, and modify data.
What are MongoDB, NoSQL, Redis, memcached?