tomcat-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From mt...@apache.org
Subject svn commit: r701754 - in /tomcat/connectors/trunk/jk: native/common/ xdocs/miscellaneous/ xdocs/reference/
Date Sun, 05 Oct 2008 07:05:52 GMT
Author: mturk
Date: Sun Oct  5 00:05:51 2008
New Revision: 701754

URL: http://svn.apache.org/viewvc?rev=701754&view=rev
Log:
Rename retry_wait to retry_interval. It means exactly that; 'the interval between retries'

Modified:
    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_util.c
    tomcat/connectors/trunk/jk/native/common/jk_util.h
    tomcat/connectors/trunk/jk/xdocs/miscellaneous/changelog.xml
    tomcat/connectors/trunk/jk/xdocs/reference/workers.xml

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?rev=701754&r1=701753&r2=701754&view=diff
==============================================================================
--- tomcat/connectors/trunk/jk/native/common/jk_ajp_common.c (original)
+++ tomcat/connectors/trunk/jk/native/common/jk_ajp_common.c Sun Oct  5 00:05:51 2008
@@ -2095,7 +2095,7 @@
     int log_error;
     int rc = JK_UNSET;
     char *msg = "";
-    int retry_wait;
+    int retry_interval;
 
     JK_TRACE_ENTER(l);
 
@@ -2198,7 +2198,7 @@
         aw->s->state = JK_AJP_STATE_PROBE;
     if (aw->s->busy > aw->s->max_busy)
         aw->s->max_busy = aw->s->busy;
-    retry_wait = p->worker->retry_wait;
+    retry_interval = p->worker->retry_interval;
     for (i = 0; i < aw->retries; i++) {
         /*
          * ajp_send_request() already locally handles
@@ -2206,12 +2206,12 @@
          * So if we already failed in it, wait a bit before
          * retrying the same backend.
          */
-        if (i > 0 && retry_wait >= 0) {
+        if (i > 0 && retry_interval >= 0) {
             if (JK_IS_DEBUG_LEVEL(l))
                 jk_log(l, JK_LOG_DEBUG,
                        "retry %d, sleeping for %d ms before retrying",
-                       i, retry_wait);
-            jk_sleep(retry_wait);
+                       i, retry_interval);
+            jk_sleep(retry_interval);
         }
         /*
          * We're using op->request which hold initial request
@@ -2554,8 +2554,8 @@
         p->socket_buf =
             jk_get_worker_socket_buffer(props, p->name, p->max_packet_size);
 
-        p->retry_wait =
-            jk_get_worker_retry_wait(props, p->name,
+        p->retry_interval =
+            jk_get_worker_retry_interval(props, p->name,
                                      JK_SLEEP_DEF);
 
         p->http_status_fail_num = jk_get_worker_fail_on_status(props, p->name,
@@ -2625,8 +2625,8 @@
                     p->max_packet_size);
 
             jk_log(l, JK_LOG_DEBUG,
-                   "retry wait time:  %d",
-                    p->retry_wait);
+                   "retry interval:   %d",
+                    p->retry_interval);
         }
         /*
          *  Need to initialize secret here since we could return from inside

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?rev=701754&r1=701753&r2=701754&view=diff
==============================================================================
--- tomcat/connectors/trunk/jk/native/common/jk_ajp_common.h (original)
+++ tomcat/connectors/trunk/jk/native/common/jk_ajp_common.h Sun Oct  5 00:05:51 2008
@@ -337,7 +337,7 @@
 
     unsigned int max_packet_size;  /*  Maximum AJP Packet size */
 
-    int retry_wait;                /*  Number of milliseconds to sleep before doing a retry
*/
+    int retry_interval;            /*  Number of milliseconds to sleep before doing a retry
*/
 
     /* 
      * HTTP status that will cause failover (0 means disabled)

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?rev=701754&r1=701753&r2=701754&view=diff
==============================================================================
--- tomcat/connectors/trunk/jk/native/common/jk_lb_worker.c (original)
+++ tomcat/connectors/trunk/jk/native/common/jk_lb_worker.c Sun Oct  5 00:05:51 2008
@@ -1095,7 +1095,7 @@
             ajp_worker_t *aw = (ajp_worker_t *)rec->worker->worker_private;
             jk_endpoint_t *end = NULL;
             int retry = 0;
-            int retry_wait = JK_LB_MIN_RETRY_WAIT;
+            int retry_interval = JK_LB_MIN_RETRY_INTERVAL;
 
             if (!s->route)
                 s->route = rec->route;
@@ -1117,12 +1117,12 @@
 
             while ((!(r=rec->worker->get_endpoint(rec->worker, &end, l)) ||
!end) && (retry < p->worker->retries)) {
                 retry++;
-                retry_wait *=2;
+                retry_interval *=2;
 
                 if (p->worker->lblock == JK_LB_LOCK_PESSIMISTIC)
                     jk_shm_lock();
-                if (retry_wait > JK_LB_MAX_RETRY_WAIT)
-                    retry_wait = JK_LB_MAX_RETRY_WAIT;
+                if (retry_interval > JK_LB_MAX_RETRY_INTERVAL)
+                    retry_interval = JK_LB_MAX_RETRY_INTERVAL;
                 if (p->worker->lblock == JK_LB_LOCK_PESSIMISTIC)
                     jk_shm_unlock();
 
@@ -1130,8 +1130,8 @@
                     jk_log(l, JK_LOG_DEBUG,
                            "could not get free endpoint for worker"
                            " (retry %d, sleeping for %d ms)",
-                           retry, retry_wait);
-                jk_sleep(retry_wait);
+                           retry, retry_interval);
+                jk_sleep(retry_interval);
             }
             if (!r || !end) {
                 /* If we can not get the endpoint

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?rev=701754&r1=701753&r2=701754&view=diff
==============================================================================
--- tomcat/connectors/trunk/jk/native/common/jk_lb_worker.h (original)
+++ tomcat/connectors/trunk/jk/native/common/jk_lb_worker.h Sun Oct  5 00:05:51 2008
@@ -122,9 +122,9 @@
 #define JK_NOTE_LB_LAST_STATE        ("JK_LB_LAST_STATE")
 
 /* Minimal time in ms to wait between get_endpoint retries for balanced workers */
-#define JK_LB_MIN_RETRY_WAIT  (25)
+#define JK_LB_MIN_RETRY_INTERVAL     (25)
 /* Maximal time in ms to wait between get_endpoint retries for balanced workers */
-#define JK_LB_MAX_RETRY_WAIT  (100)
+#define JK_LB_MAX_RETRY_INTERVAL     (100)
 /* Time to wait before retry. */
 #define WAIT_BEFORE_RECOVER   (60)
 /* We accept doing global maintenance if we are */

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?rev=701754&r1=701753&r2=701754&view=diff
==============================================================================
--- tomcat/connectors/trunk/jk/native/common/jk_util.c (original)
+++ tomcat/connectors/trunk/jk/native/common/jk_util.c Sun Oct  5 00:05:51 2008
@@ -86,7 +86,7 @@
 #define ACTIVATION_OF_WORKER        ("activation")
 #define WORKER_RECOVER_TIME         ("recover_time")
 #define MAX_REPLY_TIMEOUTS_OF_WORKER ("max_reply_timeouts")
-#define RETRY_WAIT_OF_WORKER        ("retry_wait")
+#define RETRY_INTERVAL_OF_WORKER    ("retry_interval")
 #define WORKER_MAX_PACKET_SIZE      ("max_packet_size")
 #define STYLE_SHEET_OF_WORKER       ("css")
 #define NAMESPACE_OF_WORKER         ("ns")
@@ -202,7 +202,7 @@
     ACTIVATION_OF_WORKER,
     WORKER_RECOVER_TIME,
     MAX_REPLY_TIMEOUTS_OF_WORKER,
-    RETRY_WAIT_OF_WORKER,
+    RETRY_INTERVAL_OF_WORKER,
     WORKER_MAX_PACKET_SIZE,
     STYLE_SHEET_OF_WORKER,
     READ_ONLY_OF_WORKER,
@@ -295,7 +295,7 @@
     ACTIVATION_OF_WORKER,
     WORKER_RECOVER_TIME,
     MAX_REPLY_TIMEOUTS_OF_WORKER,
-    RETRY_WAIT_OF_WORKER,
+    RETRY_INTERVAL_OF_WORKER,
     WORKER_MAX_PACKET_SIZE,
     STYLE_SHEET_OF_WORKER,
     NAMESPACE_OF_WORKER,
@@ -970,7 +970,7 @@
     return jk_map_get_int(m, buf, def);
 }
 
-int jk_get_worker_retry_wait(jk_map_t *m, const char *wname, int def)
+int jk_get_worker_retry_interval(jk_map_t *m, const char *wname, int def)
 {
     char buf[1024];
 
@@ -978,7 +978,7 @@
         return -1;
     }
 
-    MAKE_WORKER_PARAM(RETRY_WAIT_OF_WORKER);
+    MAKE_WORKER_PARAM(RETRY_INTERVAL_OF_WORKER);
 
     return jk_map_get_int(m, buf, def);
 }

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?rev=701754&r1=701753&r2=701754&view=diff
==============================================================================
--- tomcat/connectors/trunk/jk/native/common/jk_util.h (original)
+++ tomcat/connectors/trunk/jk/native/common/jk_util.h Sun Oct  5 00:05:51 2008
@@ -98,7 +98,7 @@
 
 int jk_get_worker_max_reply_timeouts(jk_map_t *m, const char *wname, int def);
 
-int jk_get_worker_retry_wait(jk_map_t *m, const char *wname, int def);
+int jk_get_worker_retry_interval(jk_map_t *m, const char *wname, int def);
 
 const char *jk_get_worker_route(jk_map_t *m, const char *wname, const char *def);
 

Modified: tomcat/connectors/trunk/jk/xdocs/miscellaneous/changelog.xml
URL: http://svn.apache.org/viewvc/tomcat/connectors/trunk/jk/xdocs/miscellaneous/changelog.xml?rev=701754&r1=701753&r2=701754&view=diff
==============================================================================
--- tomcat/connectors/trunk/jk/xdocs/miscellaneous/changelog.xml (original)
+++ tomcat/connectors/trunk/jk/xdocs/miscellaneous/changelog.xml Sun Oct  5 00:05:51 2008
@@ -47,7 +47,7 @@
         Status: Add display of seconds since last statistics reset. (rjung)
       </update>
       <add>
-        AJP13: Add a configurable retry wait time. (rjung)
+        AJP13: Add a configurable retry_interval time. (rjung)
       </add>
       <update>
         Documentation: Enhance description of connection_pool_size. (rjung)

Modified: tomcat/connectors/trunk/jk/xdocs/reference/workers.xml
URL: http://svn.apache.org/viewvc/tomcat/connectors/trunk/jk/xdocs/reference/workers.xml?rev=701754&r1=701753&r2=701754&view=diff
==============================================================================
--- tomcat/connectors/trunk/jk/xdocs/reference/workers.xml (original)
+++ tomcat/connectors/trunk/jk/xdocs/reference/workers.xml Sun Oct  5 00:05:51 2008
@@ -729,14 +729,14 @@
 sleeping time.
 <p>
 See also the attribute <b>recovery_options</b> for a more fine-grained control
-of retries and <b>retry_wait</b> for the sleep time configuration.
+of retries and <b>retry_interval</b> for the sleep time configuration.
 </p>
 <p>
 Until version <b>1.2.16</b> the default value was 3.
 </p>
 </directive>
 
-<directive name="retry_wait" workers="AJP,SUB" default="100" required="false">
+<directive name="retry_interval" workers="AJP,SUB" default="100" required="false">
 The amount of time in milliseconds the worker sleeps before doing any retry.
 <p>
 This features has been added in <b>jk 1.2.27</b>.



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


Mime
View raw message