durusmail: quixote-users: Overlaying a static directory
Overlaying a static directory
2005-04-11
2005-04-12
2005-04-12
2005-04-12
2005-04-13
2005-04-13
2005-04-14
2005-04-14
2005-04-14
2005-04-14
2005-04-14
2005-04-14
2005-04-14
2005-04-14
2005-04-14
2005-04-14
David Binger (3 parts)
2005-04-14
2005-04-14
2005-04-13
2005-04-14
2005-04-14
2005-04-13
SCGI util.
2005-04-12
2005-04-13
2005-04-13
2005-04-13
2005-04-13
Overlaying a static directory
Neil Schemenauer
2005-04-14
On Wed, Apr 13, 2005 at 11:37:11PM -0400, Ryan Tomayko wrote:
> Crap. I've run into this issue before. IIRC, when the SCGI piece sent a
> future date back to apache in the Last-Modified header, apache didn't
> like it.

That's the same bug.  What's happening is that mod_scgi is
incorrectly handing the return value from
ap_scan_script_header_err_buff() and
ap_scan_script_header_err_brigade().  mod_scgi always returns the
error code for "internal server error" but that's wrong since those
functions can return other error codes.

The reason is that they check for some HTTP/1.1 conditional GETs,
for example If-Modified-Since.  Normally the Quixote StaticFile
object handles If-Modified-Since but it only checks for exact
matches.

Changing mod_scgi to handling of the return value does not,
unfortunately, fix the problem.  The result sounds like what Mike is
seeing when he tries to use cgi2scgi.  On some requests the client
ends up hanging for a few seconds, waiting for a response from the
server.  Looking at the HTTP TCP stream reveals that the hang is due
to HTTP/1.1 keep-alive.  The final response returns by the server
looks invalid since it is missing a content-length header.  The
server thinks it is done and waits for another request over the same
connection while the client continues to wait for the response.

I'm still investigating.  Next I will try to reproduce the same
behavior with a regular CGI script.

  Neil

reply