tomcat-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From funk...@apache.org
Subject cvs commit: jakarta-tomcat-catalina/catalina/src/bin catalina.sh
Date Thu, 31 Jul 2003 15:03:04 GMT
funkman     2003/07/31 08:03:04

  Modified:    catalina/src/bin catalina.sh
  Log:
  Port os400 change from 4.1.
  
  Actually just copied the entire file from 4.1 to here. And kept the
  -force logic.
  
  This worked fine with cygwin. The diff seems innocent.
  
  Comments on -sourcepath
     "$CATALINA_HOME"/../../jakarta-tomcat-4.0/catalina/src/share ?
  
  Does anyone debug with a debugger on 5? Should this be removed?
  
  Revision  Changes    Path
  1.7       +50 -26    jakarta-tomcat-catalina/catalina/src/bin/catalina.sh
  
  Index: catalina.sh
  ===================================================================
  RCS file: /home/cvs/jakarta-tomcat-catalina/catalina/src/bin/catalina.sh,v
  retrieving revision 1.6
  retrieving revision 1.7
  diff -u -r1.6 -r1.7
  --- catalina.sh	20 Mar 2003 23:30:45 -0000	1.6
  +++ catalina.sh	31 Jul 2003 15:03:04 -0000	1.7
  @@ -40,8 +40,10 @@
   
   # OS specific support.  $var _must_ be set to either true or false.
   cygwin=false
  +os400=false
   case "`uname`" in
   CYGWIN*) cygwin=true;;
  +OS400*) os400=true;;
   esac
   
   # resolve links - $0 may be a softlink
  @@ -68,10 +70,23 @@
   if $cygwin; then
     [ -n "$JAVA_HOME" ] && JAVA_HOME=`cygpath --unix "$JAVA_HOME"`
     [ -n "$CATALINA_HOME" ] && CATALINA_HOME=`cygpath --unix "$CATALINA_HOME"`
  +  [ -n "$CATALINA_BASE" ] && CATALINA_BASE=`cygpath --unix "$CATALINA_BASE"`
     [ -n "$CLASSPATH" ] && CLASSPATH=`cygpath --path --unix "$CLASSPATH"`
     [ -n "$JSSE_HOME" ] && JSSE_HOME=`cygpath --path --unix "$JSSE_HOME"`
   fi
   
  +# For OS400
  +if $os400; then
  +  # Set job priority to standard for interactive (interactive - 6) by using
  +  # the interactive priority - 6, the helper threads that respond to requests
  +  # will be running at the same priority as interactive jobs.
  +  COMMAND='chgjob job('$JOBNAME') runpty(6)'
  +  system $COMMAND
  +
  +  # Enable multi threading
  +  export QIBM_MULTI_THREADED=Y
  +fi
  +
   # Get standard Java environment variables
   if [ -r "$CATALINA_HOME"/bin/setclasspath.sh ]; then
     BASEDIR="$CATALINA_HOME"
  @@ -130,27 +145,32 @@
   
   if [ "$1" = "debug" ] ; then
   
  -  shift
  -  if [ "$1" = "-security" ] ; then
  -    echo "Using Security Manager"
  -    shift
  -    exec "$_RUNJDB" $JAVA_OPTS $CATALINA_OPTS \
  -      -Djava.endorsed.dirs="$JAVA_ENDORSED_DIRS" -classpath "$CLASSPATH" \
  -      -sourcepath "$CATALINA_HOME"/../../jakarta-tomcat-4.0/catalina/src/share \
  -      -Djava.security.manager \
  -      -Djava.security.policy=="$CATALINA_BASE"/conf/catalina.policy \
  -      -Dcatalina.base="$CATALINA_BASE" \
  -      -Dcatalina.home="$CATALINA_HOME" \
  -      -Djava.io.tmpdir="$CATALINA_TMPDIR" \
  -      org.apache.catalina.startup.Bootstrap "$@" start
  +  if $os400; then
  +    echo "Debug command not available on OS400"
  +    exit 1
     else
  -    exec "$_RUNJDB" $JAVA_OPTS $CATALINA_OPTS \
  -      -Djava.endorsed.dirs="$JAVA_ENDORSED_DIRS" -classpath "$CLASSPATH" \
  -      -sourcepath "$CATALINA_HOME"/../../jakarta-tomcat-4.0/catalina/src/share \
  -      -Dcatalina.base="$CATALINA_BASE" \
  -      -Dcatalina.home="$CATALINA_HOME" \
  -      -Djava.io.tmpdir="$CATALINA_TMPDIR" \
  -      org.apache.catalina.startup.Bootstrap "$@" start
  +    shift
  +    if [ "$1" = "-security" ] ; then
  +      echo "Using Security Manager"
  +      shift
  +      exec "$_RUNJDB" $JAVA_OPTS $CATALINA_OPTS \
  +        -Djava.endorsed.dirs="$JAVA_ENDORSED_DIRS" -classpath "$CLASSPATH" \
  +        -sourcepath "$CATALINA_HOME"/../../jakarta-tomcat-4.0/catalina/src/share \
  +        -Djava.security.manager \
  +        -Djava.security.policy=="$CATALINA_BASE"/conf/catalina.policy \
  +        -Dcatalina.base="$CATALINA_BASE" \
  +        -Dcatalina.home="$CATALINA_HOME" \
  +        -Djava.io.tmpdir="$CATALINA_TMPDIR" \
  +        org.apache.catalina.startup.Bootstrap "$@" start
  +    else
  +      exec "$_RUNJDB" $JAVA_OPTS $CATALINA_OPTS \
  +        -Djava.endorsed.dirs="$JAVA_ENDORSED_DIRS" -classpath "$CLASSPATH" \
  +        -sourcepath "$CATALINA_HOME"/../../jakarta-tomcat-4.0/catalina/src/share \
  +        -Dcatalina.base="$CATALINA_BASE" \
  +        -Dcatalina.home="$CATALINA_HOME" \
  +        -Djava.io.tmpdir="$CATALINA_TMPDIR" \
  +        org.apache.catalina.startup.Bootstrap "$@" start
  +    fi
     fi
   
   elif [ "$1" = "embedded" ] ; then
  @@ -206,7 +226,7 @@
   
         if [ ! -z "$CATALINA_PID" ]; then
           echo $! > $CATALINA_PID
  -      fi      
  +      fi
     else
       "$_RUNJAVA" $JAVA_OPTS $CATALINA_OPTS \
         -Djava.endorsed.dirs="$JAVA_ENDORSED_DIRS" -classpath "$CLASSPATH" \
  @@ -218,7 +238,7 @@
   
         if [ ! -z "$CATALINA_PID" ]; then
           echo $! > $CATALINA_PID
  -      fi      
  +      fi
     fi
   
   elif [ "$1" = "stop" ] ; then
  @@ -239,13 +259,17 @@
       fi
     fi
   
  -
   else
   
     echo "Usage: catalina.sh ( commands ... )"
     echo "commands:"
  -  echo "  debug             Start Catalina in a debugger"
  -  echo "  debug -security   Debug Catalina with a security manager"
  +  if $os400; then
  +    echo "  debug             Start Catalina in a debugger (not available on OS400)"
  +    echo "  debug -security   Debug Catalina with a security manager (not available on
OS400)"
  +  else
  +    echo "  debug             Start Catalina in a debugger"
  +    echo "  debug -security   Debug Catalina with a security manager"
  +  fi
     echo "  embedded          Start Catalina in embedded mode"
     echo "  jpda start        Start Catalina under JPDA debugger"
     echo "  run               Start Catalina in the current window"
  
  
  

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


Mime
View raw message