httpd-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Life is hard, and then you die" <>
Subject Re: HTTP compliance and pipelined requests
Date Thu, 29 Jun 2000 09:32:54 GMT
On Wed, Jun 28, 2000 at 03:28:06PM -0700, Jordi Ros wrote:
> My concern is the same as yours, Bill. I'm not very familiar with the
> dispatcher problem but yes you are right, in-kernel mini servers such as
> kHTTPd may suffer from the synchorinization of HTTP responses. For the
> current version of kHTTPd this is not a problem since it only supports HTTP
> 1.0.

This is a little tricky. Strictly speaking HTTP/1.0 did not have keep-alive,
so yes, there aren't any pipelining problems. However, nothing prohibits
an HTTP/1.0 client which uses keep-alive's from pipelining, so you really
have this problem in HTTP/1.0 too.

> >From section 4.4 of RFC 2616 basically we have four ways to know the end of
> a response: content-length, server closing the connection, 0 byte chunk,
> multipart/byterange. All of them except the server closing the connection
> require parsing the HTTP payload. So one way to solve the issue is to
> implement a mini-parser in the kHTTPd that intercepts and parses the
> responses coming from Apache to know where is the end. But this does not
> look like a very efficient solution. Any comments on this would be very
> welcome?

I don't see any way around the parser. You need to figure out where the
response ends. Parsing and skipping based on Content-Length and chunks
is easy; only multipart/byte-ranges is really ugly.

> Also, I wold like somebody to make comments on the following quote taken
> from the book "Internetworking with TCP/IP" 4th Edition:
> "To allow a TCP connection to persist through multiple requests and
> responses, HTTP sends a length before each resonse. If it does not know  the
> length, a server informs the client, sends the response, and then closes"
> Is this true for Apache? According to the emails you have been sending
> Apache provides others ways other that closing of the connection such as the
> 0 byte chunk. Any comments on this quote are very welcome too. Thanks!!

That seems to be referring to HTTP/1.0 with keep-alive's, not to HTTP/1.1.
0-length chunk and multipart/byte-ranges are only in HTTP/1.1. Apache has
been doing HTTP/1.1 for smething like 3 years now.



View raw message