httpd-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Marc Slemko <>
Subject Re: cvs commit: apache-2.0/docs page_io
Date Sun, 08 Mar 1998 05:43:28 GMT
On Sat, 7 Mar 1998, Dean Gaudet wrote:

> Man that sucks.  If HTTP-NG doesn't allow individual streams/whatever
> they're called to push at least page-sized data chunks then it's going to
> royally suck for server performance. 

>From what I see, the protocol supports it fine, it is just a matter of
having to follow what the client asks for.  We all know how much you can
trust clients.  On top of that, most clients on slow connections will
probably want less than page sized chunks.  Hmm.  Or perhaps not.

> BTW, I'm not sure how we can support sendfile/TransmitFile unless we put
> them into the BUFF API as primitives... which is kind of awkward, but not
> impossible.  Defaults are pretty easy to implement for layers that don't
> have a better way to do it.  But upper layers may be able to do something
> more efficiently with knowledge that a lower layer doesn't implement
> sendfile... still easy to do, you can always do something like:
>     if (fb->top_filter->sendfile) {
> 	do something with sendfile
>     }
>     else {
> 	do something that's more efficient than generic sendfile handling
>     }

Some sort of API function that just gets the data from a descriptor plus
header and trailer to the network should work for most situations, no?
Then it is simply done with read/write or mmap or sendfile depending on
the OS.

But yes, we do need some explicit support for the concept of going from a
descriptor to the network without copys.  I don't see that as being a bad

View raw message