DotCloud open-sources its websocket proxy
blog.dotcloud.com
blog.dotcloud.com
Before building Hipache, dotCloud's network routing layer consisted of a large number of boxes running nginx, wrapped in a custom instrumentation and management layer which, among other things, generated configuration files of mind-boggling size several times per minute and propagated them across a fairly complex distributed system. If we had used haproxy, we would have had to adapt that ad-hoc instrumentation layer to haproxy - not a particularly pleasant prospect. Since dotCloud had reached a scale which mandated a redesign of the routing layer anyway, we killed two birds with one stone.
- Support for persistent (keep-alive) connections. A small detail which bit me when I deployed using Haproxy: it sets the X-Forwarded-For header only for the first request. Subsequent requests on the same connection will not include that header.
However one thing that jumps out at me is the low number of tests. There only appear to be a few Acceptance tests. For a serious bit of software like a load balancer I would expect to see a fair few unit tests.
e.g. getBackendFromHostHeader inside worker.js does a lot of things, if I were the author I would have it wrapped up in unit tests.