Author: jfrederic.clere(a)jboss.com
Date: 2008-07-02 05:31:16 -0400 (Wed, 02 Jul 2008)
New Revision: 1733
Modified:
trunk/mod_cluster/native/mod_proxy_cluster/mod_proxy_cluster.c
Log:
Arrange mapping.
Modified: trunk/mod_cluster/native/mod_proxy_cluster/mod_proxy_cluster.c
===================================================================
--- trunk/mod_cluster/native/mod_proxy_cluster/mod_proxy_cluster.c 2008-06-26 15:24:05 UTC
(rev 1732)
+++ trunk/mod_cluster/native/mod_proxy_cluster/mod_proxy_cluster.c 2008-07-02 09:31:16 UTC
(rev 1733)
@@ -675,7 +675,7 @@
vhosts = apr_palloc(r->pool, sizeof(int)*sizevhost);
sizevhost = host_storage->get_ids_used_host(vhosts);
ap_log_error(APLOG_MARK, APLOG_DEBUG, 0, r->server,
- "get_context_host_balancer testing node %s",
node->mess.JVMRoute);
+ "get_context_host_balancer testing node %s for %s",
node->mess.JVMRoute, r->uri);
for (i=0; i<sizevhost; i++) {
hostinfo_t *vhost;
host_storage->read_host(vhosts[i], &vhost);
@@ -701,16 +701,20 @@
/* check for /context[/] in the URL */
len = strlen(context->context);
if (strncmp(r->uri, context->context, len) == 0) {
- if (r->uri[len] == '\0' || r->uri[len] ==
'/') {
+ if (r->uri[len] == '\0' || r->uri[len-1] ==
'/') {
/* Check status */
switch (context->status)
{
case ENABLED:
+ ap_log_error(APLOG_MARK, APLOG_DEBUG, 0, r->server,
+ "get_context_host_balancer found
context %s", context->context);
return node->mess.balancer;
break;
case DISABLED:
/* Only the request with sessionid ok for it */
if (hassession_byname(r, node->mess.balancer, conf))
+ ap_log_error(APLOG_MARK, APLOG_DEBUG, 0,
r->server,
+ "get_context_host_balancer found
(DISABLED) context %s", context->context);
return node->mess.balancer;
break;
}
@@ -721,6 +725,8 @@
}
}
}
+ ap_log_error(APLOG_MARK, APLOG_DEBUG, 0, r->server,
+ "get_context_host_balancer NOT found");
return NULL;
}
Show replies by date