hbase-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From nspiegelb...@apache.org
Subject svn commit: r1181407 - /hbase/branches/0.89/bin/rolling-restart.sh
Date Tue, 11 Oct 2011 02:05:56 GMT
Author: nspiegelberg
Date: Tue Oct 11 02:05:56 2011
New Revision: 1181407

URL: http://svn.apache.org/viewvc?rev=1181407&view=rev
Log:
Rolling Upgrade: Configurable Per-RS Sleep

Summary:
Stop hardcoding HBASE_SLAVE_SLEEP

Test Plan:
./bin/rolling-upgrade.sh
./bin/rolling-upgrade.sh --sleep 10

DiffCamp Revision: 171503
Reviewed By: kannan
CC: nspiegelberg, kannan
Revert Plan:
OK

Modified:
    hbase/branches/0.89/bin/rolling-restart.sh

Modified: hbase/branches/0.89/bin/rolling-restart.sh
URL: http://svn.apache.org/viewvc/hbase/branches/0.89/bin/rolling-restart.sh?rev=1181407&r1=1181406&r2=1181407&view=diff
==============================================================================
--- hbase/branches/0.89/bin/rolling-restart.sh (original)
+++ hbase/branches/0.89/bin/rolling-restart.sh Tue Oct 11 02:05:56 2011
@@ -48,13 +48,19 @@ then
   exit $errCode
 fi
 
+if [ $# -gt 1 ] && [ "--sleep" = "$1" ]; then
+  shift
+  export HBASE_SLAVE_SLEEP=$1
+  shift
+else
+  export HBASE_SLAVE_SLEEP=15
+fi
+
 # quick function to get a value from the HBase config file
 distMode=`$bin/hbase org.apache.hadoop.hbase.HBaseConfTool hbase.cluster.distributed`
 if [ "$distMode" == 'false' ]; then
   "$bin"/hbase-daemon.sh restart master
 else
-  export HBASE_SLAVE_SLEEP=60
-
   # stop all masters before re-start to avoid races for master znode
   "$bin"/hbase-daemon.sh --config "${HBASE_CONF_DIR}" stop master
   "$bin"/hbase-daemons.sh --config "${HBASE_CONF_DIR}" \



Mime
View raw message