This is a follow up to the discussion I started in my comment to PR36816: I am currently wondering what identifies a proxy worker. >From what I read in ap_proxy_get_worker in proxy_util.c it is identified by worker->name. But I see a problem here: The url passed for comparison here gets reduced effectively to schema, hostname and port of the worker, but worker->name also contains a path if one was added during configuration as it is the result of apr_uri_unparse(p, &uri, APR_URI_UNP_REVEALPASSWORD); As an example I take the one from PR36816:
<Proxy balancer://test1> BalancerMember http://my.server.com:1234 BalancerMember http://otner.server.com:1234/myapp </Proxy> So the worker http://otner.server.com:1234/myapp can never be found by ap_proxy_get_worker. >From what I understand from other parts of the code the worker should be >identified by the full URL. So I think the following patch should be applied to ap_proxy_get_worker Index: proxy_util.c =================================================================== --- proxy_util.c (Revision 295013) +++ proxy_util.c (Arbeitskopie) @@ -1218,9 +1218,6 @@ c = strchr(uri, ':'); if (c == NULL || c[1] != '/' || c[2] != '/' || c[3] == '\0') return NULL; - /* remove path from uri */ - if ((c = strchr(c + 3, '/'))) - *c = '\0'; worker = (proxy_worker *)conf->workers->elts; for (i = 0; i < conf->workers->nelts; i++) { Last but not least all information that identifies a worker should be displayed by the manager application. Thoughts / comments? Regards RĂ¼diger On 10/05/2005 08:44 PM, Colin Murtaugh wrote: > Attached is a patch for bug 36816. The balancer_manager interface > offered by mod_proxy_balancer doesn't work properly if a worker name > contains a port number. > > E.g. if I have configured a cluster as: > > <Proxy balancer://testcluster> > BalancerMember http://server-one.mydomain.com:1234 > BalancerMember http://server-two.mydomain.com:1234 > </Proxy> > > then I'm not able to edit the worker settings via the > balancer_manager. This is because the worker->name is being compared > to worker->hostname; worker->name contains the port and worker- >>hostname does not. > > I've created the patch below to fix this problem. > > --Colin > >