21 messages in org.apache.httpd.devRe: Is async the answer
FromSent OnAttachments
Akins, Brian18 Jan 2008 10:52 
Justin Erenkrantz18 Jan 2008 11:16 
Colm MacCarthaigh18 Jan 2008 11:20 
Akins, Brian18 Jan 2008 11:27 
Akins, Brian18 Jan 2008 11:31 
Colm MacCarthaigh18 Jan 2008 12:07 
Akins, Brian18 Jan 2008 13:17 
Colm MacCarthaigh18 Jan 2008 13:29 
Ruediger Pluem18 Jan 2008 14:30 
Justin Erenkrantz18 Jan 2008 16:33 
Niklas Edmundsson19 Jan 2008 03:53 
Graham Leggett19 Jan 2008 04:45 
Davi Arnaut19 Jan 2008 06:57 
Jim Jagielski19 Jan 2008 07:04 
Graham Leggett19 Jan 2008 08:02 
Henrik Nordström19 Jan 2008 13:14 
Henrik Nordström19 Jan 2008 13:19 
Davi Arnaut19 Jan 2008 15:29 
Graham Leggett20 Jan 2008 07:44 
Akins, Brian22 Jan 2008 10:03 
Akins, Brian22 Jan 2008 10:08 
Subject:Re: Is async the answer
From:Henrik Nordström (hen@henriknordstrom.net)
Date:01/19/2008 01:14:45 PM
List:org.apache.httpd.dev

fre 2008-01-18 klockan 16:17 -0500 skrev Akins, Brian:

Paul Q and I have been kicking around the idea that even if we go to a completely async core, etc. that modules could mark some hooks as "blocking" and they would run basically how they do today. (One day, Paul, I'll actually think about this more...)

In the end you need a bit of mixture between the models to work out. threads or even processes for complex processing or libraries outside your control, and async for the basic core to keep it lightweight in resources/request/connection.

There is quite a bit of research in programming models supporting mixed async/threaded/tasklet scheduling without forcing the programmer to know all details. Quite interesting reading if you haven't read those papers yet.

For example the tame approach (C++ preprocessor using libasync) used by OKWS and it's related cousin tamer (more lightweight library) is quite fun to work with, at least in theory.

Regarding CPU performance then you need a more complex workload than pure sendfile() shuffling of data to see much of a difference between threaded or async models. Especially if you look at smaller requests where the two almost diverge to the same model.. (N threads doing fast successive batch processing one request at a time with no wait time, or a event loop doing pretty much the same batching..).

Regards Henrik