170 points · by huhtenberg · 13y ago · 127 comments
HN is not a service, its not a startup trying to get mindshare - its a (luvvie alert) community - and one where the downtime had a known and obvious cause and did not matter - rtm would fix it, I would catch up, I knew this thread would exist and I would still get insight into what is happening 12 hours ahead of everyone else.
I thought I would be more bothered - turns out I am emotionally invested, not emotionally dependant.
To PG et al, good luck with the fixes, and thanks.
Cheers
"just one summer with the RSC back when I was younger".
"Of course Johnny said, ... umm, Gielguld of course dahling, did you see him in the Tempest in 74? Wunderful"
"I was saying to Sam just after that Quantum thing. You really should talk to Barbara about directing the next one. I have her number; charming lady, did I ever tell you about the time she ..."
A small red rotating flashing light will rise up out of the coffee table next to you and the words "luvvie alert" will be flashed across your field of vision.
EDIT: More proof -- downvoted -- what could be more hellish than to ban humor?
BUT I'd much rather get rid of the "this link has expired" syndrome.
Fast is only impressive if the results are modern.
I do that much more often than I hit an expired link.
Here's an example. Currently if you go to the home page and then click the "More" link at the bottom to go to the next page, and wait long enough, the more link expires. That's because it's currently implemented as something like this (not sure about ARC syntax, I'll use Scheme syntax here, but you get the idea):
(define (show-list-of-posts page-number)
... display the rest of the homepage ...
(link "More" (lambda () (show-list-of-posts (+ 1 page-number)))))
This stores the closure `(lambda () (show-list-of-posts (+ 1 page-number)))` with the free variable `page-number` in a hash table on the server. The URL becomes an index into that hash table. But the only information needed to reconstruct such a closure, is the function body and the free variables. So if we defined an auxilary function: (define (foo page-number)
(show-list-of-posts (+ 1 page-number)))
then we could represent the closure as the pair ("foo",page-number). If we encode that in the URL, then instead of looking up the closure from the hash table, we can reconstruct the closure on the fly. Hence we do no longer have to store anything on the server, and no links can expire anymore.There are some challenges when you want to do this transformation automatically, but they can be overcome.
I don't think this is strictly true. The comments and reply links simply link to a normal (non-closure) URL on the site and the page is generated from that URL in the normal manner.
Great explanation of what's causing that - thank you!
I suspect hindering spam and vote manipulation plays a part in the architectural decisions. It also makes it possible to create different HN's for different users - e.g. the hellbanned, royals, and plebeians.
This is particularly infuriating on a cellphone.
One quick fix: in the code that prints this message, check to see if the request was a comment-post action. If so, append, "...but for your convenience, here's the text you tried to post, so it's not lost forever: [...]"
(Just watch out for XSS!)
After seeing this thing down for several hours -- and Google hate downtimes, they punish you instantly -- I think: "Maybe not."
However, happy to hear what went wrong and why we still should go for the bare metal thing.
seems the issue was more with the migration.
so i reckon you're good to get back to removing all the threads from your apps :)
EDIT: since Heroku fooled Rapgenius and us all it would be one more reason to get into system operations again and host on bare metal.
Timing some pages, the response is around 350ms. That means 95% of the loading time is networking, not generation time. You're right, the server is really fast given the load HN brings down on one server!
Then to utilize this you want a load balancer in front that's unlikely to fail and if it fails can be restarted rapidly. This load balancer should send requests to the other server as soon as one has failed. The other option is DNS failover, which can work but has different trade-offs.
One thing that this does not protect you against is repeatable failure due to a software bug. If a request comes in that happens to crash one of your servers, load will be quickly switched to the other. But the user that cause the original server to crash might refresh his page because he didn't get any response back, which also sends the problematic request to the other server, and might crash that one too. These kind of problems are very hard to deal with (if the requests don't come from humans but from programs that automatically retry their request to other servers when they don't get a response it's even worse: a single bad request can bring an entire cluster down in seconds).
Paradoxically sometimes measures to improve availability can cause availability to go down. If you make your architecture more complicated you introduce more opportunities for failure, especially due to bugs. If you have multiple servers in a pipeline, for example a load balancer and then the real servers which in turn talk to the database servers, that can also cause your likelihood to fail due to hardware to increase. If your pipeline depth is three, then the chance that you have a hardware failure is about three times as big compared to when you had a pipeline depth of one. You want to minimize the depth and maximize the width of the pipeline.
So you should ask yourself whether it's worth it, especially when you're small. Many of the successful sites had or still have a lot of downtime. Maybe it's better to minimize the duration of downtime with fast restarts rather than trying to lower the probability of downtime.
I did visit one of those quickly and the result was HN should be reachable... Hmmmm, therefore I. Checked with another age and this also timed out on my tablet. So either my ADSL or the server was problematic? I went for dinner and upon return it worked.
The check I used was http://www.blockedinchina.net/ First time I used this site...
When I saw http://www.downforeveryoneorjustme.com/http://news.ycombinat... I realized that I wasn't.
But you could have easily met me. Mostly Linux events... mail me if you want to know
Apologies for the HN outage. We think it may be related
to the new server. This could take a while to fix.
[1] https://twitter.com/paulg/status/303350671460147200Just because the switch-over went smoothly doesn't mean that normal operations didn't fall apart later on.
Alternatively you know... you can just accept that the service will be down for an hour or two and most people wouldn't even notice without this post.
Bonus points if you do actually. Their search API is limited to 100 a day, which is not a lot.