Author: schultz
Date: Tue Jul 16 19:51:00 2013
New Revision: 1503851

URL: http://svn.apache.org/r1503851
Log:
Fix https://issues.apache.org/bugzilla/show_bug.cgi?id=55268

Added optional --service-start-wait-time command-line option to change service 
start wait time from default of 10 seconds.


Modified:
    tomcat/trunk/bin/daemon.sh

Modified: tomcat/trunk/bin/daemon.sh
URL: 
http://svn.apache.org/viewvc/tomcat/trunk/bin/daemon.sh?rev=1503851&r1=1503850&r2=1503851&view=diff
==============================================================================
--- tomcat/trunk/bin/daemon.sh (original)
+++ tomcat/trunk/bin/daemon.sh Tue Jul 16 19:51:00 2013
@@ -62,6 +62,11 @@ do
         shift; shift;
         continue
     ;;
+    --service-start-wait-time )
+        SERVICE_START_WAIT_TIME="$2"
+        shift; shift;
+        continue
+    ;;
     * )
         break
     ;;
@@ -102,6 +107,8 @@ test ".$CATALINA_HOME" = . && CATALINA_H
 test ".$CATALINA_BASE" = . && CATALINA_BASE="$CATALINA_HOME"
 test ".$CATALINA_MAIN" = . && 
CATALINA_MAIN=org.apache.catalina.startup.Bootstrap
 test ".$JSVC" = . && JSVC="$CATALINA_BASE/bin/jsvc"
+# Set the default service-start wait time if necessary
+test -z "$SERVICE_START_WAIT_TIME" && SERVICE_START_WAIT_TIME=10
 
 # Ensure that any user defined CLASSPATH variables are not used on startup,
 # but allow them to be specified in setenv.sh, in rare case when it is needed.
@@ -169,7 +176,7 @@ case "$1" in
       $JSVC_OPTS \
       -java-home "$JAVA_HOME" \
       -pidfile "$CATALINA_PID" \
-      -wait 10 \
+      -wait "$SERVICE_START_WAIT_TIME" \
       -nodetach \
       -outfile "&1" \
       -errfile "&2" \
@@ -187,7 +194,7 @@ case "$1" in
       -java-home "$JAVA_HOME" \
       -user $TOMCAT_USER \
       -pidfile "$CATALINA_PID" \
-      -wait 10 \
+      -wait "$SERVICE_START_WAIT_TIME" \
       -outfile "$CATALINA_OUT" \
       -errfile "&1" \
       -classpath "$CLASSPATH" \



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

Reply via email to