I plan on archiving messages, and I'm not sure which I should use.
It should be able to hold a maximum of 20 billions rows (that's what I expect the total number to tend to)
Each row will have three columns : user_id, message, date
The user_id is a string of 30 characters. The message is anywhere between 1 - 20 000 characters. On average I expect it to be 140 characters. (UTF-8, it should allow emojis, different alphabets, etc)
I only want an index for the user_id, not for the message/date.
I only plan on doing INSERT queries, and very simple SELECT * WHERE user_id = XXXXX
There will be very little SELECTs, I expect at its peak 10 / minute.
The SELECTs don't need to be fast, anything between 1-20 seconds is fine.
But there will be a lot of INSERTs. Probably about 5000-10000 per seconds.
My server will have:
CPU: AMD Ryzen™ 9 7950X3D
RAM: 128 GB DDR5 ECC
Drives: 1x 7.68 TB NVMe SSD Datacenter
(From Hetzner)
Asked by lyeaf
(307 rep)
Nov 27, 2023, 06:59 PM
Last activity: Nov 28, 2023, 01:51 PM
Last activity: Nov 28, 2023, 01:51 PM