News for hackers. Stuff that matters.
Re:Ask HN: How do I handle a million hits a minute? by ulysses on Wednesday November 12, 2008 @11:40AM (#361961)
You could cache or replicate the database for reads. When a post comes in, insert it into the master database, then sleep for a preset amount of time, then have it start checking the local database copy to wait for it to show up, then run the query. Just use timestamp <= posters_timestamp to get the result set you want.

Adjust the sleep time based how frequent the cache updates are.

There are no comments on this comment yet.