Bug 41560 - proxy_handler can return apr_status_t
Summary: proxy_handler can return apr_status_t
Status: RESOLVED LATER
Alias: None
Product: Apache httpd-2
Classification: Unclassified
Component: mod_proxy (show other bugs)
Version: 2.2.4
Hardware: Other other
: P2 normal (vote)
Target Milestone: ---
Assignee: Apache HTTPD Bugs Mailing List
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2007-02-07 09:10 UTC by Eric Covener
Modified: 2007-09-08 15:44 UTC (History)
0 users



Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Eric Covener 2007-02-07 09:10:36 UTC
I can see this symptom in 2.2.3 and httpd-2.2.x HEAD.

When mod_proxy_http can't read the full POST body it's expecting, it will pass
the apr_status_t return code back up the stack and proxy_handler will ultimately
return it to the core.

In 2.2.3 this results in %s being logged as 70007 (timeout). In 2.2.x HEAD the
core notes the non-HTTP return code and uses 500 for %s:

[Wed Feb 07 11:50:24 2007] [error] (70007)The timeout specified has expired:
proxy: prefetch request body failed to 127.0.0.1:81 (localhost) from 127.0.0.1 ()
[Wed Feb 07 11:50:24 2007] [debug] proxy_util.c(1816): proxy: HTTP: has released
connection for (localhost)
[Wed Feb 07 11:50:24 2007] [error] [client 127.0.0.1] Handler for proxy-server
returned invalid result code 70007

Because there isn't much separation between writing the request to the origin
and reading the POST body from the client, it might be difficult to bubble up
anyting but HTTP_INTERNAL_SERVER_ERROR even though HTTP_BAD_REQUEST might
sometimes be preferred.
Comment 1 Nick Kew 2007-09-08 15:44:32 UTC
This is mod_proxy's PR #31759.

It's effectively mooted by http://svn.apache.org/viewvc?view=rev&revision=448711
and looks to me more trouble than it's worth to fix.  Feel free to reopen if you
want to fix it (hey, you're a committer now:-)