tomcat-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From rj...@apache.org
Subject svn commit: r481770 - in /tomcat/connectors/trunk/jk: native/apache-1.3/ native/apache-2.0/ native/common/ native/iis/ native/netscape/ xdocs/ajp/ xdocs/config/ xdocs/miscellaneous/
Date Sun, 03 Dec 2006 12:55:58 GMT
Author: rjung
Date: Sun Dec  3 04:55:56 2006
New Revision: 481770

URL: http://svn.apache.org/viewvc?view=rev&rev=481770
Log:
Rename jvm_route to route:
- You can still use the old name in the worker configuration.
  In case of conflicts, the new name will win.
- Added jvm_route to the deprecated list in the code and
  in the docs.
- All log messages and the status worker will now only
  refer to "route".
- All internal implementation names have been changed as well.

Modified:
    tomcat/connectors/trunk/jk/native/apache-1.3/mod_jk.c
    tomcat/connectors/trunk/jk/native/apache-2.0/mod_jk.c
    tomcat/connectors/trunk/jk/native/common/jk_ajp12_worker.c
    tomcat/connectors/trunk/jk/native/common/jk_ajp_common.c
    tomcat/connectors/trunk/jk/native/common/jk_ajp_common.h
    tomcat/connectors/trunk/jk/native/common/jk_lb_worker.c
    tomcat/connectors/trunk/jk/native/common/jk_lb_worker.h
    tomcat/connectors/trunk/jk/native/common/jk_service.h
    tomcat/connectors/trunk/jk/native/common/jk_shm.h
    tomcat/connectors/trunk/jk/native/common/jk_status.c
    tomcat/connectors/trunk/jk/native/common/jk_util.c
    tomcat/connectors/trunk/jk/native/common/jk_util.h
    tomcat/connectors/trunk/jk/native/iis/jk_isapi_plugin.c
    tomcat/connectors/trunk/jk/native/netscape/jk_nsapi_plugin.c
    tomcat/connectors/trunk/jk/xdocs/ajp/ajpv13a.xml
    tomcat/connectors/trunk/jk/xdocs/ajp/ajpv13ext.xml
    tomcat/connectors/trunk/jk/xdocs/config/workers.xml
    tomcat/connectors/trunk/jk/xdocs/miscellaneous/changelog.xml

Modified: tomcat/connectors/trunk/jk/native/apache-1.3/mod_jk.c
URL: http://svn.apache.org/viewvc/tomcat/connectors/trunk/jk/native/apache-1.3/mod_jk.c?view=diff&rev=481770&r1=481769&r2=481770
==============================================================================
--- tomcat/connectors/trunk/jk/native/apache-1.3/mod_jk.c (original)
+++ tomcat/connectors/trunk/jk/native/apache-1.3/mod_jk.c Sun Dec  3 04:55:56 2006
@@ -496,7 +496,7 @@
 {
     request_rec *r = private_data->r;
     char *ssl_temp = NULL;
-    s->jvm_route = NULL;        /* Used for sticky session routing */
+    s->route = NULL;        /* Used for sticky session routing */
 
     /* Copy in function pointers (which are really methods) */
     s->start_response = ws_start_response;
@@ -2008,8 +2008,8 @@
                         ap_psprintf(r->pool, "%.1ld.%.6ld", seconds, micro);
                     ap_table_setn(r->notes, JK_NOTE_REQUEST_DURATION, duration);
 #endif
-                    if (s.jvm_route && *s.jvm_route)
-                        ap_table_setn(r->notes, JK_NOTE_WORKER_ROUTE, s.jvm_route);
+                    if (s.route && *s.route)
+                        ap_table_setn(r->notes, JK_NOTE_WORKER_ROUTE, s.route);
                     request_log_transaction(r, conf);
                 }
             }

Modified: tomcat/connectors/trunk/jk/native/apache-2.0/mod_jk.c
URL: http://svn.apache.org/viewvc/tomcat/connectors/trunk/jk/native/apache-2.0/mod_jk.c?view=diff&rev=481770&r1=481769&r2=481770
==============================================================================
--- tomcat/connectors/trunk/jk/native/apache-2.0/mod_jk.c (original)
+++ tomcat/connectors/trunk/jk/native/apache-2.0/mod_jk.c Sun Dec  3 04:55:56 2006
@@ -516,7 +516,7 @@
     request_rec *r = private_data->r;
 
     char *ssl_temp = NULL;
-    s->jvm_route = NULL;        /* Used for sticky session routing */
+    s->route = NULL;        /* Used for sticky session routing */
 
     /* Copy in function pointers (which are really methods) */
     s->start_response = ws_start_response;
@@ -2101,8 +2101,8 @@
 
                 duration = apr_psprintf(r->pool, "%.1ld.%.6ld", seconds, micro);
                 apr_table_setn(r->notes, JK_NOTE_REQUEST_DURATION, duration);
-                if (s.jvm_route && *s.jvm_route)
-                    apr_table_setn(r->notes, JK_NOTE_WORKER_ROUTE, s.jvm_route);
+                if (s.route && *s.route)
+                    apr_table_setn(r->notes, JK_NOTE_WORKER_ROUTE, s.route);
 
                 request_log_transaction(r, xconf);
             }

Modified: tomcat/connectors/trunk/jk/native/common/jk_ajp12_worker.c
URL: http://svn.apache.org/viewvc/tomcat/connectors/trunk/jk/native/common/jk_ajp12_worker.c?view=diff&rev=481770&r1=481769&r2=481770
==============================================================================
--- tomcat/connectors/trunk/jk/native/common/jk_ajp12_worker.c (original)
+++ tomcat/connectors/trunk/jk/native/common/jk_ajp12_worker.c Sun Dec  3 04:55:56 2006
@@ -400,7 +400,7 @@
            ajpv12_sendstring(p, s->server_name) &&
 #endif
            ajpv12_sendint(p, s->server_port) && ajpv12_sendstring(p, s->protocol)
&& ajpv12_sendstring(p, 0) && /* SERVER_SIGNATURE */
-           ajpv12_sendstring(p, s->server_software) && ajpv12_sendstring(p, s->jvm_route)
&&    /* JSERV_ROUTE */
+           ajpv12_sendstring(p, s->server_software) && ajpv12_sendstring(p, s->route)
&&    /* JSERV_ROUTE */
            ajpv12_sendstring(p, "") &&  /* JSERV ajpv12 compatibility */
            ajpv12_sendstring(p, ""));   /* JSERV ajpv12 compatibility */
 

Modified: tomcat/connectors/trunk/jk/native/common/jk_ajp_common.c
URL: http://svn.apache.org/viewvc/tomcat/connectors/trunk/jk/native/common/jk_ajp_common.c?view=diff&rev=481770&r1=481769&r2=481770
==============================================================================
--- tomcat/connectors/trunk/jk/native/common/jk_ajp_common.c (original)
+++ tomcat/connectors/trunk/jk/native/common/jk_ajp_common.c Sun Dec  3 04:55:56 2006
@@ -348,7 +348,7 @@
     ?remote_user   (byte)(string)
     ?auth_type     (byte)(string)
     ?query_string  (byte)(string)
-    ?jvm_route     (byte)(string)
+    ?route         (byte)(string)
     ?ssl_cert      (byte)(string)
     ?ssl_cipher    (byte)(string)
     ?ssl_session   (byte)(string)
@@ -457,11 +457,11 @@
             return JK_FALSE;
         }
     }
-    if (s->jvm_route) {
-        if (jk_b_append_byte(msg, SC_A_JVM_ROUTE) ||
-            jk_b_append_string(msg, s->jvm_route)) {
+    if (s->route) {
+        if (jk_b_append_byte(msg, SC_A_ROUTE) ||
+            jk_b_append_string(msg, s->route)) {
             jk_log(l, JK_LOG_ERROR,
-                   "failed appending the jvm route");
+                   "failed appending the route");
             JK_TRACE_EXIT(l);
             return JK_FALSE;
         }

Modified: tomcat/connectors/trunk/jk/native/common/jk_ajp_common.h
URL: http://svn.apache.org/viewvc/tomcat/connectors/trunk/jk/native/common/jk_ajp_common.h?view=diff&rev=481770&r1=481769&r2=481770
==============================================================================
--- tomcat/connectors/trunk/jk/native/common/jk_ajp_common.h (original)
+++ tomcat/connectors/trunk/jk/native/common/jk_ajp_common.h Sun Dec  3 04:55:56 2006
@@ -43,7 +43,7 @@
 #define SC_A_REMOTE_USER        (unsigned char)3
 #define SC_A_AUTH_TYPE          (unsigned char)4
 #define SC_A_QUERY_STRING       (unsigned char)5
-#define SC_A_JVM_ROUTE          (unsigned char)6
+#define SC_A_ROUTE              (unsigned char)6
 #define SC_A_SSL_CERT           (unsigned char)7
 #define SC_A_SSL_CIPHER         (unsigned char)8
 #define SC_A_SSL_SESSION        (unsigned char)9

Modified: tomcat/connectors/trunk/jk/native/common/jk_lb_worker.c
URL: http://svn.apache.org/viewvc/tomcat/connectors/trunk/jk/native/common/jk_lb_worker.c?view=diff&rev=481770&r1=481769&r2=481770
==============================================================================
--- tomcat/connectors/trunk/jk/native/common/jk_lb_worker.c (original)
+++ tomcat/connectors/trunk/jk/native/common/jk_lb_worker.c Sun Dec  3 04:55:56 2006
@@ -473,9 +473,9 @@
     unsigned int i;
 
     for (i = 0; i < p->num_of_workers; i++) {
-        if (strcmp(p->lb_workers[i].s->jvm_route, name) == 0) {
+        if (strcmp(p->lb_workers[i].s->route, name) == 0) {
             rc = &p->lb_workers[i];
-            rc->r = &(rc->s->jvm_route[0]);
+            rc->r = &(rc->s->route[0]);
             break;
         }
     }
@@ -615,9 +615,9 @@
     worker_record_t *rc = NULL;
 
     rc = find_best_byvalue(p, l);
-    /* By default use worker jvm route as session route */
+    /* By default use worker route as session route */
     if (rc)
-        rc->r = &(rc->s->jvm_route[0]);
+        rc->r = &(rc->s->route[0]);
     else
         rc = find_failover_worker(p, l);
     return rc;
@@ -638,7 +638,7 @@
          */
         if (JK_WORKER_USABLE_STICKY(p->lb_workers[0].s)) {
             if (p->lb_workers[0].s->activation != JK_LB_ACTIVATION_DISABLED) {
-                p->lb_workers[0].r = &(p->lb_workers[0].s->jvm_route[0]);
+                p->lb_workers[0].r = &(p->lb_workers[0].s->route[0]);
                 JK_TRACE_EXIT(l);
                 return &p->lb_workers[0];
             }
@@ -691,7 +691,7 @@
                     if (JK_IS_DEBUG_LEVEL(l))
                         jk_log(l, JK_LOG_DEBUG,
                                "found worker %s (%s) for route %s and partial sessionid %s",
-                               rc->s->name, rc->s->jvm_route, session_route,
sessionid);
+                               rc->s->name, rc->s->route, session_route, sessionid);
                         JK_TRACE_EXIT(l);
                     return rc;
                 }
@@ -722,7 +722,7 @@
     if (rc && JK_IS_DEBUG_LEVEL(l)) {
         jk_log(l, JK_LOG_DEBUG,
                "found best worker %s (%s) using method '%s'",
-               rc->s->name, rc->s->jvm_route, jk_lb_get_method(p, l));
+               rc->s->name, rc->s->route, jk_lb_get_method(p, l));
     }
     JK_TRACE_EXIT(l);
     return rc;
@@ -791,13 +791,13 @@
             jk_endpoint_t *end = NULL;
             int retry = 0;
             int retry_wait = JK_LB_MIN_RETRY_WAIT;
-            s->jvm_route = rec->r;
+            s->route = rec->r;
             prec = rec;
 
             if (JK_IS_DEBUG_LEVEL(l))
                 jk_log(l, JK_LOG_DEBUG,
-                       "service worker=%s jvm_route=%s",
-                       rec->s->name, s->jvm_route);
+                       "service worker=%s route=%s",
+                       rec->s->name, s->route);
             while ((!(r=rec->w->get_endpoint(rec->w, &end, l)) || !end) &&
(retry < p->worker->s->retries)) {
                 retry++;
                 retry_wait *=2;
@@ -1172,10 +1172,10 @@
                     p->max_packet_size = ms;
                 p->lb_workers[i].s->distance =
                     jk_get_distance(props, worker_names[i]);
-                if ((s = jk_get_worker_jvm_route(props, worker_names[i], NULL)))
-                    strncpy(p->lb_workers[i].s->jvm_route, s, JK_SHM_STR_SIZ);
+                if ((s = jk_get_worker_route(props, worker_names[i], NULL)))
+                    strncpy(p->lb_workers[i].s->route, s, JK_SHM_STR_SIZ);
                 else
-                    strncpy(p->lb_workers[i].s->jvm_route, worker_names[i], JK_SHM_STR_SIZ);
+                    strncpy(p->lb_workers[i].s->route, worker_names[i], JK_SHM_STR_SIZ);
                 if ((s = jk_get_worker_domain(props, worker_names[i], NULL)))
                     strncpy(p->lb_workers[i].s->domain, s, JK_SHM_STR_SIZ);
                 if ((s = jk_get_worker_redirect(props, worker_names[i], NULL)))
@@ -1207,22 +1207,22 @@
                 close_workers(p, i, l);
             }
             else {
-                /* Update domain names if jvm_route contains period '.' */
+                /* Update domain names if route contains period '.' */
                 for (i = 0; i < num_of_workers; i++) {
                     if (!p->lb_workers[i].s->domain[0]) {
-                        char * id_domain = strchr(p->lb_workers[i].s->jvm_route, '.');
+                        char * id_domain = strchr(p->lb_workers[i].s->route, '.');
                         if (id_domain) {
                             *id_domain = '\0';
-                            strcpy(p->lb_workers[i].s->domain, p->lb_workers[i].s->jvm_route);
+                            strcpy(p->lb_workers[i].s->domain, p->lb_workers[i].s->route);
                             *id_domain = '.';
                         }
                     }
                     if (JK_IS_DEBUG_LEVEL(l)) {
                         jk_log(l, JK_LOG_DEBUG,
-                               "Balanced worker %i has name %s and jvm_route %s in domain
%s",
+                               "Balanced worker %i has name %s and route %s in domain %s",
                                i,
                                p->lb_workers[i].s->name,
-                               p->lb_workers[i].s->jvm_route,
+                               p->lb_workers[i].s->route,
                                p->lb_workers[i].s->domain);
                     }
                 }
@@ -1230,14 +1230,14 @@
                 update_mult(p, l);
                 for (i = 0; i < num_of_workers; i++) {
                     for (j = 0; j < i; j++) {
-                        if (strcmp(p->lb_workers[i].s->jvm_route, p->lb_workers[j].s->jvm_route)
== 0) {
+                        if (strcmp(p->lb_workers[i].s->route, p->lb_workers[j].s->route)
== 0) {
                             jk_log(l, JK_LOG_ERROR,
-                                   "Balanced workers number %i (%s) and %i (%s) share the
same jvm_route %s - aborting configuration!",
+                                   "Balanced workers number %i (%s) and %i (%s) share the
same route %s - aborting configuration!",
                                    i,
                                    p->lb_workers[i].s->name,
                                    j,
                                    p->lb_workers[j].s->name,
-                                   p->lb_workers[i].s->jvm_route);
+                                   p->lb_workers[i].s->route);
                             JK_TRACE_EXIT(l);
                             return JK_FALSE;
                         }

Modified: tomcat/connectors/trunk/jk/native/common/jk_lb_worker.h
URL: http://svn.apache.org/viewvc/tomcat/connectors/trunk/jk/native/common/jk_lb_worker.h?view=diff&rev=481770&r1=481769&r2=481770
==============================================================================
--- tomcat/connectors/trunk/jk/native/common/jk_lb_worker.h (original)
+++ tomcat/connectors/trunk/jk/native/common/jk_lb_worker.h Sun Dec  3 04:55:56 2006
@@ -114,7 +114,7 @@
     jk_worker_t      *w;
     /* Shared memory worker data */
     jk_shm_worker_t  *s;
-    /* Current jvmRoute. Can be name or domain */
+    /* Current route. Can be name or domain */
     const char       *r;
 };
 typedef struct worker_record worker_record_t;

Modified: tomcat/connectors/trunk/jk/native/common/jk_service.h
URL: http://svn.apache.org/viewvc/tomcat/connectors/trunk/jk/native/common/jk_service.h?view=diff&rev=481770&r1=481769&r2=481770
==============================================================================
--- tomcat/connectors/trunk/jk/native/common/jk_service.h (original)
+++ tomcat/connectors/trunk/jk/native/common/jk_service.h Sun Dec  3 04:55:56 2006
@@ -187,12 +187,12 @@
     unsigned num_attributes;        /* Number of request attributes     */
 
     /*
-     * The jvm route is in use when the adapter load balance among
-     * several JVMs. It is the ID of a specific JVM in the load balance
-     * group. We are using this variable to implement JVM session
+     * The route is in use when the adapter load balance among
+     * several workers. It is the ID of a specific target in the load balance
+     * group. We are using this variable to implement target session
      * affinity
      */
-    const char *jvm_route;
+    const char *route;
 
     /* Temp solution for auth. For native1 it'll be sent on each request,
        if an option is present. For native2 it'll be sent with the first

Modified: tomcat/connectors/trunk/jk/native/common/jk_shm.h
URL: http://svn.apache.org/viewvc/tomcat/connectors/trunk/jk/native/common/jk_shm.h?view=diff&rev=481770&r1=481769&r2=481770
==============================================================================
--- tomcat/connectors/trunk/jk/native/common/jk_shm.h (original)
+++ tomcat/connectors/trunk/jk/native/common/jk_shm.h Sun Dec  3 04:55:56 2006
@@ -71,8 +71,8 @@
     volatile int connected;
     /* worker name */
     char    name[JK_SHM_STR_SIZ+1];
-    /* jvm route */
-    char    jvm_route[JK_SHM_STR_SIZ+1];
+    /* route */
+    char    route[JK_SHM_STR_SIZ+1];
     /* worker domain */
     char    domain[JK_SHM_STR_SIZ+1];
     /* worker redirect route */

Modified: tomcat/connectors/trunk/jk/native/common/jk_status.c
URL: http://svn.apache.org/viewvc/tomcat/connectors/trunk/jk/native/common/jk_status.c?view=diff&rev=481770&r1=481769&r2=481770
==============================================================================
--- tomcat/connectors/trunk/jk/native/common/jk_status.c (original)
+++ tomcat/connectors/trunk/jk/native/common/jk_status.c Sun Dec  3 04:55:56 2006
@@ -821,7 +821,7 @@
                     "</td>", NULL);
             jk_printf(s, "<td>%u</td>", wr->s->busy);
             jk_printf(s, "<td>%u</td>", wr->s->max_busy);
-            jk_putv(s, "<td>", wr->s->jvm_route, "</td><td>", NULL);
+            jk_putv(s, "<td>", wr->s->route, "</td><td>", NULL);
             if (wr->s->redirect && *wr->s->redirect)
                 jk_puts(s, wr->s->redirect);
             else
@@ -955,7 +955,7 @@
             jk_printf(s, "        address=\"%s\"\n", jk_dump_hinfo(&a->worker_inet_addr,
buf));
             jk_printf(s, "        activation=\"%s\"\n", jk_lb_get_activation(wr, l));
             jk_printf(s, "        lbfactor=\"%d\"\n", wr->s->lb_factor);
-            jk_printf(s, "        jvm_route=\"%s\"\n", wr->s->jvm_route ? wr->s->jvm_route
: "");
+            jk_printf(s, "        route=\"%s\"\n", wr->s->route ? wr->s->route
: "");
             jk_printf(s, "        redirect=\"%s\"\n", wr->s->redirect ? wr->s->redirect
: "");
             jk_printf(s, "        domain=\"%s\"\n", wr->s->domain ? wr->s->domain
: "");
             jk_printf(s, "        distance=\"%d\"\n", wr->s->distance);
@@ -1087,7 +1087,7 @@
             jk_printf(s, " address=%s", jk_dump_hinfo(&a->worker_inet_addr, buf));
             jk_printf(s, " activation=%s", jk_lb_get_activation(wr, l));
             jk_printf(s, " lbfactor=%d", wr->s->lb_factor);
-            jk_printf(s, " jvm_route=%s", wr->s->jvm_route ? wr->s->jvm_route
: "");
+            jk_printf(s, " route=%s", wr->s->route ? wr->s->route : "");
             jk_printf(s, " redirect=%s", wr->s->redirect ? wr->s->redirect :
"");
             jk_printf(s, " domain=%s", wr->s->domain ? wr->s->domain : "");
             jk_printf(s, " distance=%d", wr->s->distance);
@@ -1316,7 +1316,7 @@
     jk_putv(s, "<tr><td>", JK_STATUS_ARG_LBM_TEXT_ROUTE,
             ":</td><td><input name=\"",
             JK_STATUS_ARG_LBM_ROUTE, "\" type=\"text\" ", NULL);
-    jk_printf(s, "value=\"%s\"/></td></tr>\n", wr->s->jvm_route);
+    jk_printf(s, "value=\"%s\"/></td></tr>\n", wr->s->route);
     jk_putv(s, "<tr><td>", JK_STATUS_ARG_LBM_TEXT_REDIRECT,
             ":</td><td><input name=\"",
             JK_STATUS_ARG_LBM_REDIRECT, "\" type=\"text\" ", NULL);
@@ -1440,7 +1440,7 @@
             }
             else if (!strcmp(attribute, JK_STATUS_ARG_LBM_ROUTE)) {
                 jk_printf(s, "<input name=\"val%d\" type=\"text\"", i);
-                jk_putv(s, "value=\"", wr->s->jvm_route, "\"/>\n", NULL);
+                jk_putv(s, "value=\"", wr->s->route, "\"/>\n", NULL);
             }
             else if (!strcmp(attribute, JK_STATUS_ARG_LBM_REDIRECT)) {
                 jk_printf(s, "<input name=\"val%d\" type=\"text\"", i);
@@ -1585,16 +1585,16 @@
     }
     if ((rv = status_get_arg(JK_STATUS_ARG_LBM_ROUTE,
                              s->query_string, buf, sizeof(buf))) == JK_TRUE) {
-        if (strncmp(wr->s->jvm_route, buf, JK_SHM_STR_SIZ)) {
+        if (strncmp(wr->s->route, buf, JK_SHM_STR_SIZ)) {
             jk_log(l, JK_LOG_INFO,
-                   "setting 'jvm_route' for sub worker '%s' of lb worker '%s' to '%s'",
+                   "setting 'route' for sub worker '%s' of lb worker '%s' to '%s'",
                    wr->s->name, worker, buf);
-            strncpy(wr->s->jvm_route, buf, JK_SHM_STR_SIZ);
+            strncpy(wr->s->route, buf, JK_SHM_STR_SIZ);
             if (!wr->s->domain[0]) {
-                char * id_domain = strchr(wr->s->jvm_route, '.');
+                char * id_domain = strchr(wr->s->route, '.');
                 if (id_domain) {
                     *id_domain = '\0';
-                    strcpy(wr->s->domain, wr->s->jvm_route);
+                    strcpy(wr->s->domain, wr->s->route);
                     *id_domain = '.';
                 }
             }
@@ -1602,9 +1602,9 @@
     }
     else if (rv == JK_UNSET) {
         jk_log(l, JK_LOG_INFO,
-               "resetting 'jvm_route' for sub worker '%s' of lb worker '%s'",
+               "resetting 'route' for sub worker '%s' of lb worker '%s'",
                wr->s->name, worker);
-        memset(wr->s->jvm_route, 0, JK_SHM_STR_SIZ);
+        memset(wr->s->route, 0, JK_SHM_STR_SIZ);
     }
     if ((rv = status_get_arg(JK_STATUS_ARG_LBM_REDIRECT,
                              s->query_string, buf, sizeof(buf))) == JK_TRUE) {
@@ -1742,16 +1742,16 @@
                 int rv = status_get_arg(vname, s->query_string, buf, sizeof(buf));
                 if (!strcmp(attribute, JK_STATUS_ARG_LBM_ROUTE)) {
                     if (rv == JK_TRUE) {
-                        if (strncmp(wr->s->jvm_route, buf, JK_SHM_STR_SIZ)) {
+                        if (strncmp(wr->s->route, buf, JK_SHM_STR_SIZ)) {
                             jk_log(l, JK_LOG_INFO,
-                                   "setting 'jvm_route' for sub worker '%s' of lb worker
'%s' to '%s'",
+                                   "setting 'route' for sub worker '%s' of lb worker '%s'
to '%s'",
                                    wr->s->name, name, buf);
-                            strncpy(wr->s->jvm_route, buf, JK_SHM_STR_SIZ);
+                            strncpy(wr->s->route, buf, JK_SHM_STR_SIZ);
                             if (!wr->s->domain[0]) {
-                                char * id_domain = strchr(wr->s->jvm_route, '.');
+                                char * id_domain = strchr(wr->s->route, '.');
                                 if (id_domain) {
                                     *id_domain = '\0';
-                                    strcpy(wr->s->domain, wr->s->jvm_route);
+                                    strcpy(wr->s->domain, wr->s->route);
                                     *id_domain = '.';
                                 }
                             }
@@ -1759,9 +1759,9 @@
                     }
                     else if (rv == JK_UNSET) {
                         jk_log(l, JK_LOG_INFO,
-                               "resetting 'jvm_route' for sub worker '%s' of lb worker '%s'",
+                               "resetting 'route' for sub worker '%s' of lb worker '%s'",
                                wr->s->name, name);
-                        memset(wr->s->jvm_route, 0, JK_SHM_STR_SIZ);
+                        memset(wr->s->route, 0, JK_SHM_STR_SIZ);
                     }
                 }
                 else if (!strcmp(attribute, JK_STATUS_ARG_LBM_REDIRECT)) {
@@ -1818,7 +1818,7 @@
             "<tbody valign=\"baseline\">\n"
             "<tr><th>Name</th><td>Worker name</td></tr>\n"
             "<tr><th>Type</th><td>Worker type</td></tr>\n"
-            "<tr><th>Route</th><td>Worker jvmRoute</td></tr>\n"
+            "<tr><th>Route</th><td>Worker route</td></tr>\n"
             "<tr><th>Addr</th><td>Backend Address info</td></tr>\n"
             "<tr><th>Act</th><td>Worker activation configuration</br>\n"
             "ACT=Active, DIS=Disabled, STP=Stopped</td></tr>\n"

Modified: tomcat/connectors/trunk/jk/native/common/jk_util.c
URL: http://svn.apache.org/viewvc/tomcat/connectors/trunk/jk/native/common/jk_util.c?view=diff&rev=481770&r1=481769&r2=481770
==============================================================================
--- tomcat/connectors/trunk/jk/native/common/jk_util.c (original)
+++ tomcat/connectors/trunk/jk/native/common/jk_util.c Sun Dec  3 04:55:56 2006
@@ -65,7 +65,8 @@
 #define BALANCE_WORKERS             ("balance_workers")
 #define STICKY_SESSION              ("sticky_session")
 #define STICKY_SESSION_FORCE        ("sticky_session_force")
-#define JVM_ROUTE_OF_WORKER         ("jvm_route")
+#define JVM_ROUTE_OF_WORKER_DEPRECATED ("jvm_route")
+#define ROUTE_OF_WORKER             ("route")
 #define DOMAIN_OF_WORKER            ("domain")
 #define REDIRECT_OF_WORKER          ("redirect")
 #define MOUNT_OF_WORKER             ("mount")
@@ -155,7 +156,8 @@
     LOAD_FACTOR_OF_WORKER,
     STICKY_SESSION,
     STICKY_SESSION_FORCE,
-    JVM_ROUTE_OF_WORKER,
+    JVM_ROUTE_OF_WORKER_DEPRECATED,
+    ROUTE_OF_WORKER,
     DOMAIN_OF_WORKER,
     REDIRECT_OF_WORKER,
     METHOD_OF_WORKER,
@@ -191,6 +193,7 @@
     CACHE_TIMEOUT_DEPRECATED,
     RECYCLE_TIMEOUT_DEPRECATED,
     BALANCED_WORKERS_DEPRECATED,
+    JVM_ROUTE_OF_WORKER_DEPRECATED,
     IS_WORKER_DISABLED_DEPRECATED,
     IS_WORKER_STOPPED_DEPRECATED,
     NULL
@@ -486,13 +489,20 @@
     return jk_map_get_string(m, buf, DEFAULT_WORKER_TYPE);
 }
 
-const char *jk_get_worker_jvm_route(jk_map_t *m, const char *wname, const char *def)
+const char *jk_get_worker_route(jk_map_t *m, const char *wname, const char *def)
 {
     char buf[1024];
+    const char *v;
     if (!m || !wname) {
         return NULL;
     }
-    MAKE_WORKER_PARAM(JVM_ROUTE_OF_WORKER);
+    MAKE_WORKER_PARAM(ROUTE_OF_WORKER);
+    v = jk_map_get_string(m, buf, NULL);
+    if (v) {
+        return v;
+    }
+    /* Try old jvm_route directive */
+    MAKE_WORKER_PARAM(JVM_ROUTE_OF_WORKER_DEPRECATED);
     return jk_map_get_string(m, buf, def);
 }
 
@@ -1507,7 +1517,7 @@
     s->attributes_names = NULL;
     s->attributes_values = NULL;
     s->num_attributes = 0;
-    s->jvm_route = NULL;
+    s->route = NULL;
     s->retries = JK_RETRIES;
     s->add_log_items = NULL;
 }

Modified: tomcat/connectors/trunk/jk/native/common/jk_util.h
URL: http://svn.apache.org/viewvc/tomcat/connectors/trunk/jk/native/common/jk_util.h?view=diff&rev=481770&r1=481769&r2=481770
==============================================================================
--- tomcat/connectors/trunk/jk/native/common/jk_util.h (original)
+++ tomcat/connectors/trunk/jk/native/common/jk_util.h Sun Dec  3 04:55:56 2006
@@ -82,7 +82,7 @@
 
 int jk_get_worker_recover_timeout(jk_map_t *m, const char *wname, int def);
 
-const char *jk_get_worker_jvm_route(jk_map_t *m, const char *wname, const char *def);
+const char *jk_get_worker_route(jk_map_t *m, const char *wname, const char *def);
 
 const char *jk_get_worker_domain(jk_map_t *m, const char *wname, const char *def);
 

Modified: tomcat/connectors/trunk/jk/native/iis/jk_isapi_plugin.c
URL: http://svn.apache.org/viewvc/tomcat/connectors/trunk/jk/native/iis/jk_isapi_plugin.c?view=diff&rev=481770&r1=481769&r2=481770
==============================================================================
--- tomcat/connectors/trunk/jk/native/iis/jk_isapi_plugin.c (original)
+++ tomcat/connectors/trunk/jk/native/iis/jk_isapi_plugin.c Sun Dec  3 04:55:56 2006
@@ -1513,7 +1513,7 @@
 
     DWORD huge_buf_sz;
 
-    s->jvm_route = NULL;
+    s->route = NULL;
 
     s->start_response = start_response;
     s->read = read;

Modified: tomcat/connectors/trunk/jk/native/netscape/jk_nsapi_plugin.c
URL: http://svn.apache.org/viewvc/tomcat/connectors/trunk/jk/native/netscape/jk_nsapi_plugin.c?view=diff&rev=481770&r1=481769&r2=481770
==============================================================================
--- tomcat/connectors/trunk/jk/native/netscape/jk_nsapi_plugin.c (original)
+++ tomcat/connectors/trunk/jk/native/netscape/jk_nsapi_plugin.c Sun Dec  3 04:55:56 2006
@@ -366,7 +366,7 @@
     char *tmp;
     int rc;
 
-    s->jvm_route = NULL;
+    s->route = NULL;
     s->start_response = start_response;
     s->read = ws_read;
     s->write = ws_write;

Modified: tomcat/connectors/trunk/jk/xdocs/ajp/ajpv13a.xml
URL: http://svn.apache.org/viewvc/tomcat/connectors/trunk/jk/xdocs/ajp/ajpv13a.xml?view=diff&rev=481770&r1=481769&r2=481770
==============================================================================
--- tomcat/connectors/trunk/jk/xdocs/ajp/ajpv13a.xml (original)
+++ tomcat/connectors/trunk/jk/xdocs/ajp/ajpv13a.xml Sun Dec  3 04:55:56 2006
@@ -520,7 +520,7 @@
   <tr><td>?remote_user</td><td>0x03</td><td></td></tr>
   <tr><td>?auth_type</td><td>0x04</td><td></td></tr>
   <tr><td>?query_string</td><td>0x05</td><td></td></tr>
-  <tr><td>?jvm_route</td><td>0x06</td><td></td></tr>
+  <tr><td>?route</td><td>0x06</td><td></td></tr>
   <tr><td>?ssl_cert</td><td>0x07</td><td></td></tr>
   <tr><td>?ssl_cipher</td><td>0x08</td><td></td></tr>
   <tr><td>?ssl_session</td><td>0x09</td><td></td></tr>
@@ -548,7 +548,7 @@
   <code>ssl_cipher</code>, and <code>ssl_session</code> refer to
the
   corresponding pieces of HTTP and HTTPS.
 </p><p>
-  The <code>jvm_route</code>, as I understand it, is used to support sticky
+  The <code>route</code>, as I understand it, is used to support sticky
   sessions -- associating a user's sesson with a particular Tomcat instance
   in the presence of multiple, load-balancing servers.  I don't know the
   details.

Modified: tomcat/connectors/trunk/jk/xdocs/ajp/ajpv13ext.xml
URL: http://svn.apache.org/viewvc/tomcat/connectors/trunk/jk/xdocs/ajp/ajpv13ext.xml?view=diff&rev=481770&r1=481769&r2=481770
==============================================================================
--- tomcat/connectors/trunk/jk/xdocs/ajp/ajpv13ext.xml (original)
+++ tomcat/connectors/trunk/jk/xdocs/ajp/ajpv13ext.xml Sun Dec  3 04:55:56 2006
@@ -305,7 +305,7 @@
     ?remote_user   (byte string)
     ?auth_type     (byte string)
     ?query_string  (byte string)
-    ?jvm_route     (byte string)
+    ?route         (byte string)
     ?ssl_cert      (byte string)
     ?ssl_cipher    (byte string)
     ?ssl_session   (byte string)

Modified: tomcat/connectors/trunk/jk/xdocs/config/workers.xml
URL: http://svn.apache.org/viewvc/tomcat/connectors/trunk/jk/xdocs/config/workers.xml?view=diff&rev=481770&r1=481769&r2=481770
==============================================================================
--- tomcat/connectors/trunk/jk/xdocs/config/workers.xml (original)
+++ tomcat/connectors/trunk/jk/xdocs/config/workers.xml Sun Dec  3 04:55:56 2006
@@ -583,14 +583,14 @@
 </p>
 </directive>
 
-<directive name="jvm_route" default="worker name" required="false">
+<directive name="route" default="worker name" required="false">
 Normally the name of a balanced worker in a load balancer is equal to the jvmRoute
 of the corresponding Tomcat instance. If you want to include a worker corresponding
 to a Tomcat instance into several load balancers with different balancing configuration
 (e.g. disabled, stopped) you can use this attribute.
 <p>
 Define a seperate worker per lb and per Tomcat instance with an arbitrary worker name and

-set the jvm_route attribute of the worker equal to the jvmRoute of the target Tomcat instance.
+set the route attribute of the worker equal to the jvmRoute of the target Tomcat instance.
 </p>
 <p>
 If this attribute is left empty, the name of the worker will be used.
@@ -603,8 +603,9 @@
 used as domain name, unless domain is set explicitly.
 </p>
 <p>
-This feature has been added in <b>jk 1.2.16</b>.
-The automatic domain rule has been added in <b>jk 1.2.20</b>.
+This feature has been added in <b>jk 1.2.16</b>.<br/>
+The automatic domain rule has been added in <b>jk 1.2.20</b>.<br/>
+The attribute has been renamed from jvm_route to route in <b>jk 1.2.20</b>.
 </p>
 </directive>
 
@@ -729,6 +730,27 @@
 This flag can be changed at runtime using status worker.
 <p>
 This feature has been added in <b>jk 1.2.11</b>.
+</p>
+</directive>
+
+<directive name="jvm_route" successor="route" default="worker name" required="false">
+<warn>This directive has been deprecated since 1.2.20.</warn>
+Normally the name of a balanced worker in a load balancer is equal to the jvmRoute
+of the corresponding Tomcat instance. If you want to include a worker corresponding
+to a Tomcat instance into several load balancers with different balancing configuration
+(e.g. disabled, stopped) you can use this attribute.
+<p>
+Define a seperate worker per lb and per Tomcat instance with an arbitrary worker name and

+set the jvm_route attribute of the worker equal to the jvmRoute of the target Tomcat instance.
+</p>
+<p>
+If this attribute is left empty, the name of the worker will be used.
+</p>
+<p>
+This attribute can be changed at runtime using status worker.
+</p>
+<p>
+This feature has been added in <b>jk 1.2.16</b>.
 </p>
 </directive>
 

Modified: tomcat/connectors/trunk/jk/xdocs/miscellaneous/changelog.xml
URL: http://svn.apache.org/viewvc/tomcat/connectors/trunk/jk/xdocs/miscellaneous/changelog.xml?view=diff&rev=481770&r1=481769&r2=481770
==============================================================================
--- tomcat/connectors/trunk/jk/xdocs/miscellaneous/changelog.xml (original)
+++ tomcat/connectors/trunk/jk/xdocs/miscellaneous/changelog.xml Sun Dec  3 04:55:56 2006
@@ -27,6 +27,10 @@
   <subsection name="Native">
     <changelog>
       <update>
+      Renamed jvm_route to route. Deprecated jvm_route, but still use it as fallback
+      when parsing the worker configuration. (rjung)
+      </update>
+      <update>
       IIS: Make uriworkermap file reload check interval configurable. (mturk)
       </update>
       <update>



---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@tomcat.apache.org
For additional commands, e-mail: dev-help@tomcat.apache.org


Mime
View raw message