4 ms·
It's kinda impressive that they got to 2 billion rows - with indexes, no less - without falling over.
by RainyDayTmrw 1y ago
It's kinda impressive that they got to 2 billion rows - with indexes, no less - without falling over.
- jiggawatts 1y agoPoint queries — typical of this kind of app - scales as log(n) in the number of rows. (Assuming a typical b-tree database index.) This kind of workload cheerfully “scales” to your disk capacity.
- RainyDayTmrw 1y agoLocking would make that more complex, I believe?
- jiggawatts 1y agoNot necessarily. Typically a b-tree single-row modification updates only one leaf page. Higher levels change only 1/N times where N is the number of items per page, typically in the hundreds. So three levels up the chance of a lock conflict is only 1/N^3 or about one in a million. Four levels it is one in a hundred million, etc...