httpd-bugs mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From bugzi...@apache.org
Subject DO NOT REPLY [Bug 45501] pending-request lbmethod for mod_proxy_balancer
Date Wed, 30 Jul 2008 12:39:04 GMT
https://issues.apache.org/bugzilla/show_bug.cgi?id=45501





--- Comment #1 from Ruediger Pluem <rpluem@apache.org>  2008-07-30 05:39:03 PST ---
Index: modules/proxy/mod_proxy_balancer.c
===================================================================
--- modules/proxy/mod_proxy_balancer.c  (revision 680955)
+++ modules/proxy/mod_proxy_balancer.c  (working copy)
@@ -367,7 +367,10 @@
         }
 #endif
     }
+
+    candidate->s->busy++;

This the wrong location to incerease the counter. It should be done in line
540 instead:

            apr_table_setn(r->subprocess_env, "BALANCER_ROUTE_CHANGED", "1");
        }
        *worker = runtime;
    }

+  (*worker)->s->busy++;

    /* Add balancer/worker info to env. */
    apr_table_setn(r->subprocess_env,
                   "BALANCER_NAME", (*balancer)->name);
    apr_table_setn(r->subprocess_env,
                   "BALANCER_WORKER_NAME", (*worker)->name);
    apr_table_setn(r->subprocess_env,
                   "BALANCER_WORKER_ROUTE", (*worker)->s->route);



static int rewrite_url(request_rec *r, proxy_worker *worker,
@@ -598,7 +601,9 @@

 #endif

+    worker->s->busy--;

You should check if worker is NULL here before doing the decrease

     return OK;
+
 }



-- 
Configure bugmail: https://issues.apache.org/bugzilla/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug.

---------------------------------------------------------------------
To unsubscribe, e-mail: bugs-unsubscribe@httpd.apache.org
For additional commands, e-mail: bugs-help@httpd.apache.org


Mime
View raw message