News for hackers. Stuff that matters.
Re:The Minimum Viable Rails Stack, Now Reddit Frontpage Appr... by ben_h on Saturday September 15, 2012 @02:54AM (#4525545)
Absolutely. At theconversation.edu.au we run a content site—we publish the news, which is the same for everyone. This means we can cache the front page and all the articles as static HTML, and then annotate the page with user info for signed-in commenters, editorial controls for signed-in editors, and so on.

(We have a separate cookie that is present for signed-in users, so the fronted knows whether it should fire the annotation request.)

The result is that we can serve a sudden influx of unauthenticated users (e.g. from Google News or StumbleUpon) from nginx alone, which gives us massive scale from very little hardware. It's likely that the network is actually the bottleneck in this case, and not nginx.

Re:The Minimum Viable Rails Stack, Now Reddit Frontpage Appr... by ianpri on Saturday September 15, 2012 @05:25AM (#4525753)
Interested in what you mean by annotating the page after caching it, do you have any more info on this?
Re:The Minimum Viable Rails Stack, Now Reddit Frontpage Appr... by jhealy on Saturday September 15, 2012 @09:05AM (#4526009)
The cached page contains content suitable for everyone, so it looks the the user is logged out.

An extra AJAX request grabs the users logged in status, CSRF token and similar data as JSON and then modifies the page so the user sees what they expect (a logout button, a comment form, etc).

Re:The Minimum Viable Rails Stack, Now Reddit Frontpage Appr... by rhizome on Saturday September 15, 2012 @05:49PM (#4527416)
Doesn't that cause content movement?
Re:The Minimum Viable Rails Stack, Now Reddit Frontpage Appr... by autotravis on Saturday September 15, 2012 @11:04AM (#4526218)
Essentially talking about edge side includes [http://en.wikipedia.org/wiki/Edge_Side_Includes].
Re:The Minimum Viable Rails Stack, Now Reddit Frontpage Appr... by stef25 on Saturday September 15, 2012 @04:36PM (#4527221)