Monday, September 22, 2008

lisp linux epoll web oh yeah

Lars Rune Nøstdal
View profile
More options Sep 22, 3:30 am
Newsgroups: comp.lang.lisp
From: Lars Rune Nøstdal
Date: Mon, 22 Sep 2008 12:30:39 +0200
Local: Mon, Sep 22 2008 3:30 am
Subject: Re: where is the lisp operating system? (new http server/backend for lisp)
Reply | Reply to author | Forward | Print | Individual message | Show original | Report this message | Find messages by this author

On Mon, 2008-09-22 at 08:46 +0200, Lars Rune Nøstdal wrote:
> On Sat, 2008-09-20 at 21:37 -0700, gavino wrote:
> > where is the lisp operating system?

> > If lisp is more powerful........then why is there not a working lispos
> > with a desktop and broswer?

> *rant*

Ok..that was ranty. Anyway, I'm building a new low-level HTTP backend
for SW, but this can be used for any Lisp type HTTP server. Latest test
run:

* 300 000 000 request/response round-trips (dynamically generated pages)
since yesterday; it's stable and doesn't leak memory or resources (FDs
etc.).

* 5000 concurrent sessions or always-connected clients (using HTTP
keep-alive etc.); it scales. This is probably a modest number since
normally each of the 5000 clients doesn't _constantly_ hammer the server
like I do in this test.

* ~5000 concurrent request/response round-trips pr. second with dynamic
content; it's fast.

The 5000 clients _and_ the server is currently running on the _same_
machine (old junk; standard AMD desktop hardware from late 2006). The
clients steal a lot of CPU from the server so I'll probably get higher
numbers when I get hold of a second machine for the clients.

It's based on IOLib (uses Linux epoll stuff) and the source is here:
http://common-lisp.net/~lnostdal/programming/lisp/sw-http/

The reason I'm writing this is because I need real scalability in a
"comet" or "reversed AJAX" scenario where the amount of always-connected
concurrent clients/sessions is way beyond what normal HTTP servers are
designed for.

Note that this thing is still work in progress..

..but I think this will kick some ass. When I move the clients to a
different machine it will probably handle 10000 - 20000 concurrent
always-connected clients/sessions just fine.

The idea is to keep this very low-level, fast and "scalable"; and to not
parse most things unless the user explicitly asks us to etc.

Bah .. this was ranty too .. never mind .. :}

--
Lars Rune Nøstdal || AJAX/Comet GUI type stuff for Common Lisp
http://nostdal.org/ || http://groups.google.com/group/symbolicweb

No comments: