Home > Database > SQL > body text

When do you need to use redis?

藏色散人
Release: 2020-09-18 10:18:10
Original
14439 people have browsed it

When do you need to use redis?

redis is a key-value storage system. Similar to Memcached, it supports relatively more stored value types, including string (string), list (linked list), set (set), zset (sorted set - ordered set) and hash (hash type).

When do you need to use redis?

● Does not require real-time updates but extremely consumes database data. For example, the product sales ranking list on the website can be counted once a day, and users will not pay attention to whether it is real-time.

● Data that needs to be updated in real time, but the update frequency is not high. For example, a user's order list would definitely like to be able to see the orders he has placed in real time, but most users will not place orders frequently.

● Data that is highly visited at a certain moment and updated frequently. A typical example of this kind of data is the flash sale. At the moment of the flash sale, there may be N times as much traffic as usual, and the system will be under great pressure. However, the cache used for this kind of data cannot be the same as the ordinary cache. This cache must be guaranteed not to be lost, otherwise there will be big problems.

The above is the detailed content of When do you need to use redis?. For more information, please follow other related articles on the PHP Chinese website!

Related labels:
source:php.cn
Statement of this Website
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn
Popular Tutorials
More>
Latest Downloads
More>
Web Effects
Website Source Code
Website Materials
Front End Template
About us Disclaimer Sitemap
php.cn:Public welfare online PHP training,Help PHP learners grow quickly!