Partitioning is not recommended. This is rather tricky. Difficult to maintain. Table sharding is more suitable than partitioning. The strategies for sub-tables are divided by user accounts. This post can be divided into sub-tables from 0 to N-1. The first letter or last letter of the user account can be converted into ASCII code value and set to num, and then divided moduloly by %. select * from table_num%N Sub-library can be used as a master-slave database. The master database is responsible for writing and the slave database is responsible for reading. Separation of reading and writing.
Partitioning is not recommended. This is rather tricky. Difficult to maintain. Table sharding is more suitable than partitioning. The strategies for sub-tables are divided by user accounts. This post can be divided into sub-tables from 0 to N-1. The first letter or last letter of the user account can be converted into ASCII code value and set to num, and then divided moduloly by %.
select * from table_num%N
Sub-library can be used as a master-slave database. The master database is responsible for writing and the slave database is responsible for reading. Separation of reading and writing.
1 million posts per day?
No matter how you dismantle such a large increment table, it will probably be too much.