ASF Bugzilla – Attachment 30829 Details for
Bug 54973
mod_proxy_fcgi does not honnor Timeout / ProxyTimeout
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Help
|
New Account
|
Log In
Remember
[x]
|
Forgot Password
Login:
[x]
[patch]
proposed patch v2
httpd-trunk-mod_proxy_fcgi-timeout.patch (text/plain), 2.58 KB, created by
jkaluza
on 2013-09-13 08:04:33 UTC
(
hide
)
Description:
proposed patch v2
Filename:
MIME Type:
Creator:
jkaluza
Created:
2013-09-13 08:04:33 UTC
Size:
2.58 KB
patch
obsolete
>diff --git a/modules/proxy/mod_proxy_fcgi.c b/modules/proxy/mod_proxy_fcgi.c >index 875153f..0a367b0 100644 >--- a/modules/proxy/mod_proxy_fcgi.c >+++ b/modules/proxy/mod_proxy_fcgi.c >@@ -544,7 +544,8 @@ static void dump_header_to_log(request_rec *r, unsigned char fheader[], > } > > static apr_status_t dispatch(proxy_conn_rec *conn, proxy_dir_conf *conf, >- request_rec *r, apr_uint16_t request_id) >+ proxy_server_conf *sconf, request_rec *r, >+ apr_uint16_t request_id) > { > apr_bucket_brigade *ib, *ob; > int seen_end_of_headers = 0, done = 0; >@@ -569,14 +570,20 @@ static apr_status_t dispatch(proxy_conn_rec *conn, proxy_dir_conf *conf, > ob = apr_brigade_create(r->pool, c->bucket_alloc); > > while (! done) { >- apr_interval_time_t timeout = conn->worker->s->timeout; >+ apr_interval_time_t timeout; > apr_size_t len; > int n; > > /* We need SOME kind of timeout here, or virtually anything will > * cause timeout errors. */ >- if (! conn->worker->s->timeout_set) { >- timeout = apr_time_from_sec(30); >+ if (conn->worker->s->timeout_set) { >+ timeout = conn->worker->s->timeout; >+ } >+ else if (sconf->timeout_set) { >+ timeout = sconf->timeout; >+ } >+ else { >+ timeout = r->server->timeout; > } > > rv = apr_poll(&pfd, 1, &n, timeout); >@@ -877,6 +884,7 @@ static int fcgi_do_request(apr_pool_t *p, request_rec *r, > proxy_conn_rec *conn, > conn_rec *origin, > proxy_dir_conf *conf, >+ proxy_server_conf *sconf, > apr_uri_t *uri, > char *url, char *server_portstr) > { >@@ -907,7 +915,7 @@ static int fcgi_do_request(apr_pool_t *p, request_rec *r, > } > > /* Step 3: Read records from the back end server and handle them. */ >- rv = dispatch(conn, conf, r, request_id); >+ rv = dispatch(conn, conf, sconf, r, request_id); > if (rv != APR_SUCCESS) { > ap_log_rerror(APLOG_MARK, APLOG_ERR, rv, r, APLOGNO(01075) > "Error dispatching request to %s:", server_portstr); >@@ -994,7 +1002,7 @@ static int proxy_fcgi_handler(request_rec *r, proxy_worker *worker, > } > > /* Step Three: Process the Request */ >- status = fcgi_do_request(p, r, backend, origin, dconf, uri, url, >+ status = fcgi_do_request(p, r, backend, origin, dconf, conf, uri, url, > server_portstr); > > cleanup:
You cannot view the attachment while viewing its details because your browser does not support IFRAMEs.
View the attachment on a separate page
.
View Attachment As Diff
View Attachment As Raw
Actions:
View
|
Diff
Attachments on
bug 54973
:
30828
|
30829
|
30833