Dossy Shiobara schrieb:
On 2007.09.27, Jeff Rogers <[EMAIL PROTECTED]> wrote:
[...] It seems at first glance that it would make more sense to hand
the task of writing to the connection back to the driver thread once
the connection thread is done with it, [...]

I don't know if the change was attempted, but it was certainly
considered and acknowledged as ultimately the "right thing to do" but as
I mentioned in a previous message, AOLserver's write speed hasn't been a
significant bottleneck for AOL, so the work was not pursued.

If anyone has real and actual needs to do large file serving out of
AOLserver directly and would like to either (a) make the change and
contribute it, or (b) fund its development, I would think it would be
welcomed.
This is very similar what the "background delivery" in openacs does.

Most of this can be done on the tcl layer with little effort.
I have developed a small patch for the aolserver that extends
ns_conn by two additional subcommands "channel"
and "contentsentlength", where the first one returns
the tcl channel name for a connection and the second
one is for passing the content-length to the log file.
The background delivery code passes the channel
to a event aware thread (using tcl libthread), which spools the file
to via tcl fcopy. The single delivery thread can easily handle
a few hundred simultaneous deliveries without sweat (probably
much more).

The motivation of the patch was mostly to avoid blocking of connection
threads, especially, when large files are delivered to users with slow
connections. This is especially important for openacs, where the
threads are rather fat (a few thousand tcl procs are in the blueprint),
such that the number of configured threads is rather small.

There are as well other useful applications for the patch, see e.g.
http://www.openacs.org/xowiki/weblog-portlet?ptag=bgdelivery

I have asked dossy for commit permissions to add my patches to
the aolserver  on Sept 22, 2006 and sent him the patches as well,
but my impression was that there was very little or no interest.
The patch is as well incoporated in naviserver since about this time.

The most developed install script of openacs adds the patch by default
http://www.cognovis.de/developer/en/aolserver_install

-gustaf neumann


--
AOLserver - http://www.aolserver.com/

To Remove yourself from this list, simply send an email to <[EMAIL PROTECTED]> 
with the
body of "SIGNOFF AOLSERVER" in the email message. You can leave the Subject: 
field of your email blank.

Reply via email to