Hacker News new | ask | show | jobs
by brudgers 3644 days ago
My understanding is that Hacker News does not use a database or rather it does not use a DBMS [database management system] at all. Instead it uses the OS file system and each item lives in its own file. It might be described as "flatfile" and "NoSQL" but that sort of layers an additional layer of formality on top of the simple *NIX idea that "everything is a file."

Anyway, until a few years ago, every item was had its own file and all the files were in one directory. But it got to the point that performance could not keep up with rising page views and Paul Graham reorganized all the items lexicographically into a file hierarchy base on item number to improve performance. But that optimization wasn't done until it created a problem.

It might be an interesting exercise to try to come up with reasons why an DBMS would be a better alternative to files for Hacker News.

Good luck.