A website with more than 6 million users may generate up to 30 credits per day, for example, + 1, + 2, + 5. you can also generate several points, such as-50,-100. Is there any good solution to store the user's details of these changes? Mysql does not seem to be a good solution because data... A website with more than 6 million users may generate up to 30 credits per day, for example, + 1, + 2, + 5. you can also generate several points, such as-50,-100.
Is there any good solution to store the user's details of these changes? Mysql does not seem to be a good solution because the data volume is too large.
Reply content:
A website with more than 6 million users may generate up to 30 credits per day, for example, + 1, + 2, + 5. you can also generate several points, such as-50,-100.
Is there any good solution to store the user's details of these changes? Mysql does not seem to be a good solution because the data volume is too large.
I calculate the number of requests per second for the subject. assuming that all users are active and all have 30 credits per day, the number of requests per second is calculated as follows:
600 w * 30 = 18000w18000w/86400 seconds = 2083 messages/second
As far as I know, this request volume,MySQL
But you must index the user ID.
In fact, it is certainly impossible to have so many requests online. for websites with million users, there will not be too many active users, and it is impossible for every user to increase by 30 entries every day, the amount here will be much less than estimated here (more than half estimated ).
Therefore, it is recommended that the subject analyze the data carefully, and do not shoot his head.premature optimization
.
If the subject wants to knowMySQL
Performance, here is an official page for reference: https://dev.mysql.com/tech-resources/articles/mysql-5.6.html
The landlord can consider using redis to store user points and then collect statistics on points every day and store them in MySQL.
It depends in part on the tools that the DBA team is proficient in. storage applications must be able to quickly recover from problems. If the team mainly uses mysql, take the test to filter mysql.