1. If you want to make a ranking of users" gold coins, only the highest 100 records will be displayed if displayed.
2. When it comes to using redis to do the ranking, most people will think of using sorted set to do it. But if there are millions of users and hundreds of thousands of daily active users, it would be a bit too much to put all the data on redis.
3. Is it reasonable to store the user"s information in the database first, update all the operations on the database, and then regularly take out 100 pieces of data from the database and put them in sorted zet for users to read? This reduces memory consumption and redis server write operations
4. On the other hand, how to consider whether the amount of data is too large or the IO operation is too frequent to be put on the redis?