> It turns out there is a hack in FreeBSD, invented by Filo, that causes the O/S not to give a new connection to the server until an entire HTTP request has arrived. This might reduce the number of threads a lot, and thus improve performance; I'll give it a try today or tomorrow. Anyone know if they're referring to "accept filters" here? FreeBSD folks can "man accf_http" if they're curious, which does prevent a reque…
this seems impossible for item pages due to how continuation ids are used for replies
Why HN was slow and how Rtm fixed it
51–60 of 202 posts
Re: Why HN was slow and how Rtm fixed it
#52I feel silly asking, but who or what is 'rtm'?
2: same acronym as RTFM, but polite.
Re: Why HN was slow and how Rtm fixed it
#53Re: Why HN was slow and how Rtm fixed it
#54I write time-critical applications in Clojure and JVM's -XX:+UseConcMarkSweepGC flag is a lifesaver. We no longer get those multi-second pauses when full GC occurs.
Re: Why HN was slow and how Rtm fixed it
#55Sounds like a switch to async I/O would be helpful.
Re: Why HN was slow and how Rtm fixed it
#56Reverse-proxying via nginx would solve this problem and more: the arbitrary 30 second limit on form submission (hotspots sometimes are slow...), nginx could handle rate limiting & logging instead of srv.arc, etc. The Arc codebase would btw be smaller and cleaner (no policy/sanitization code, etc.). Serving static content via Apache was a first step ;-) Don't reinvent the wheel!
They think they can build a better wheel. They seem to like doing it and have a habit of it. There's nothing wrong with that.
Re: Why HN was slow and how Rtm fixed it
#57Who's Filo? David Filo?
Re: Why HN was slow and how Rtm fixed it
#58> when [MzScheme] wants to find a thread to run, it asks the O/S kernel about each socket in turn to see if any input is ready They've never heard of select()? But really, is there some reason that it's hard to collect up all the fds at once or something?
Read C10K? Both select() and poll() have this problem internally. You have to use one of the more advanced techniques available if you really want to scale. epoll(), kqueue() or friends.
Re: Why HN was slow and how Rtm fixed it
#59Re: Why HN was slow and how Rtm fixed it
#60Lisp is definitely not a slow language: you can handle the crazy rate of 20 requests/second on a multi-core server!