httpd-cvs mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From j..@apache.org
Subject svn commit: r1728325 - /httpd/httpd/trunk/modules/proxy/mod_proxy_hcheck.c
Date Wed, 03 Feb 2016 14:30:53 GMT
Author: jim
Date: Wed Feb  3 14:30:53 2016
New Revision: 1728325

URL: http://svn.apache.org/viewvc?rev=1728325&view=rev
Log:
Only health-check workers which are not STOPPED
Only log Checking if we are actually checking

Modified:
    httpd/httpd/trunk/modules/proxy/mod_proxy_hcheck.c

Modified: httpd/httpd/trunk/modules/proxy/mod_proxy_hcheck.c
URL: http://svn.apache.org/viewvc/httpd/httpd/trunk/modules/proxy/mod_proxy_hcheck.c?rev=1728325&r1=1728324&r2=1728325&view=diff
==============================================================================
--- httpd/httpd/trunk/modules/proxy/mod_proxy_hcheck.c (original)
+++ httpd/httpd/trunk/modules/proxy/mod_proxy_hcheck.c Wed Feb  3 14:30:53 2016
@@ -905,14 +905,16 @@ static apr_status_t hc_watchdog_callback
                     workers = (proxy_worker **)balancer->workers->elts;
                     for (n = 0; n < balancer->workers->nelts; n++) {
                         worker = *workers;
-                        ap_log_error(APLOG_MARK, APLOG_TRACE2, 0, s,
-                                     "Checking %s worker: %s  [%d] (%pp)", balancer->s->name,
-                                     worker->s->name, worker->s->method, worker);
-                        if ((worker->s->method != NONE) && (now > worker->s->updated
+ worker->s->interval)) {
+                        if (!PROXY_WORKER_IS(worker, PROXY_WORKER_STOPPED) &&
+                           (worker->s->method != NONE) &&
+                           (now > worker->s->updated + worker->s->interval))
{
                             baton_t *baton;
                             /* This pool must last the lifetime of the (possible) thread
*/
                             apr_pool_t *ptemp;
                             apr_pool_create(&ptemp, ctx->p);
+                            ap_log_error(APLOG_MARK, APLOG_TRACE2, 0, s,
+                                         "Checking %s worker: %s  [%d] (%pp)", balancer->s->name,
+                                         worker->s->name, worker->s->method,
worker);
 
                             if ((rv = hc_init_worker(ctx, worker)) != APR_SUCCESS) {
                                 return rv;



Mime
View raw message