cassandra-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From jbel...@apache.org
Subject svn commit: r1091139 - in /cassandra/branches/cassandra-0.8: ./ src/java/org/apache/cassandra/service/ src/java/org/apache/cassandra/tools/
Date Mon, 11 Apr 2011 17:35:42 GMT
Author: jbellis
Date: Mon Apr 11 17:35:42 2011
New Revision: 1091139

URL: http://svn.apache.org/viewvc?rev=1091139&view=rev
Log:
r/m nodetool loadbalance
patch by Nick Bailey; reviewed by jbellis for CASSANDRA-2448

Modified:
    cassandra/branches/cassandra-0.8/CHANGES.txt
    cassandra/branches/cassandra-0.8/NEWS.txt
    cassandra/branches/cassandra-0.8/src/java/org/apache/cassandra/service/StorageService.java
    cassandra/branches/cassandra-0.8/src/java/org/apache/cassandra/service/StorageServiceMBean.java
    cassandra/branches/cassandra-0.8/src/java/org/apache/cassandra/tools/NodeCmd.java
    cassandra/branches/cassandra-0.8/src/java/org/apache/cassandra/tools/NodeProbe.java

Modified: cassandra/branches/cassandra-0.8/CHANGES.txt
URL: http://svn.apache.org/viewvc/cassandra/branches/cassandra-0.8/CHANGES.txt?rev=1091139&r1=1091138&r2=1091139&view=diff
==============================================================================
--- cassandra/branches/cassandra-0.8/CHANGES.txt (original)
+++ cassandra/branches/cassandra-0.8/CHANGES.txt Mon Apr 11 17:35:42 2011
@@ -19,9 +19,11 @@
  * push replication_factor into strategy_options (CASSANDRA-1263)
  * give snapshots the same name on each node (CASSANDRA-1791)
  * add key type information and alias (CASSANDRA-2311, 2396)
+ * remove "nodetool loadbalance" (CASSANDRA-2448)
  * multithreaded compaction (CASSANDRA-2191)
  * compaction throttling (CASSANDRA-2156)
 
+
 0.7.5
  * Avoid seeking when sstable2json exports the entire file (CASSANDRA-2318)
  * fix tombstone handling in repair and sstable2json (CASSANDRA-2279)

Modified: cassandra/branches/cassandra-0.8/NEWS.txt
URL: http://svn.apache.org/viewvc/cassandra/branches/cassandra-0.8/NEWS.txt?rev=1091139&r1=1091138&r2=1091139&view=diff
==============================================================================
--- cassandra/branches/cassandra-0.8/NEWS.txt (original)
+++ cassandra/branches/cassandra-0.8/NEWS.txt Mon Apr 11 17:35:42 2011
@@ -1,5 +1,5 @@
-Whatever
-========
+0.8
+===
 
 Upgrading
 ---------
@@ -10,6 +10,9 @@ Upgrading
 	Upgrading from version 0.7.1 or later can be done with a rolling restart,
 	one node at a time.  You do not need to bring down the whole cluster.
 
+    The loadbalance command has been removed from nodetool.  For similar
+    behavior, decommission then rebootstrap with empty initial_token.
+
 Other
 -----
     In the past, sstable2json would write column names and values as hex

Modified: cassandra/branches/cassandra-0.8/src/java/org/apache/cassandra/service/StorageService.java
URL: http://svn.apache.org/viewvc/cassandra/branches/cassandra-0.8/src/java/org/apache/cassandra/service/StorageService.java?rev=1091139&r1=1091138&r2=1091139&view=diff
==============================================================================
--- cassandra/branches/cassandra-0.8/src/java/org/apache/cassandra/service/StorageService.java
(original)
+++ cassandra/branches/cassandra-0.8/src/java/org/apache/cassandra/service/StorageService.java
Mon Apr 11 17:35:42 2011
@@ -815,10 +815,9 @@ public class StorageService implements I
     }
 
     /**
-     * Handle node leaving the ring. This can be either because of decommission or loadbalance
+     * Handle node leaving the ring. This will happen when a node is decommissioned
      *
-     * @param endpoint If reason for leaving is decommission or loadbalance
-     * endpoint is the leaving node.
+     * @param endpoint If reason for leaving is decommission, endpoint is the leaving node.
      * @param pieces STATE_LEFT,token
      */
     private void handleStateLeft(InetAddress endpoint, String[] pieces)
@@ -1800,15 +1799,6 @@ public class StorageService implements I
     }
 
     /**
-     * Generates balanced token and calls load balance operation to move current node to
that token
-     * @throws IOException on any I/O operation error
-     */
-    public void loadBalance() throws IOException
-    {
-        move(BootStrapper.getBalancedToken(tokenMetadata_, StorageLoadBalancer.instance.getLoadInfo()));
-    }
-
-    /**
      * move the node to new token or find a new token to boot to according to load
      *
      * @param newToken new token to boot to, or if null, find balanced token to boot to

Modified: cassandra/branches/cassandra-0.8/src/java/org/apache/cassandra/service/StorageServiceMBean.java
URL: http://svn.apache.org/viewvc/cassandra/branches/cassandra-0.8/src/java/org/apache/cassandra/service/StorageServiceMBean.java?rev=1091139&r1=1091138&r2=1091139&view=diff
==============================================================================
--- cassandra/branches/cassandra-0.8/src/java/org/apache/cassandra/service/StorageServiceMBean.java
(original)
+++ cassandra/branches/cassandra-0.8/src/java/org/apache/cassandra/service/StorageServiceMBean.java
Mon Apr 11 17:35:42 2011
@@ -198,13 +198,6 @@ public interface StorageServiceMBean
     public void move(String newToken) throws IOException, InterruptedException;
 
     /**
-     * Node will call BootStrapper.getBalancedToken then it will calculate ranges to
-     * transfer from other nodes, load the data and move to a new token
-     * @throws IOException on any I/O error.
-     */
-    public void loadBalance() throws IOException;
-
-    /**
      * removeToken removes token (and all data associated with
      * enpoint that had it) from the ring
      */

Modified: cassandra/branches/cassandra-0.8/src/java/org/apache/cassandra/tools/NodeCmd.java
URL: http://svn.apache.org/viewvc/cassandra/branches/cassandra-0.8/src/java/org/apache/cassandra/tools/NodeCmd.java?rev=1091139&r1=1091138&r2=1091139&view=diff
==============================================================================
--- cassandra/branches/cassandra-0.8/src/java/org/apache/cassandra/tools/NodeCmd.java (original)
+++ cassandra/branches/cassandra-0.8/src/java/org/apache/cassandra/tools/NodeCmd.java Mon
Apr 11 17:35:42 2011
@@ -76,7 +76,7 @@ public class NodeCmd
     public enum NodeCommand
     {
         RING, INFO, CFSTATS, SNAPSHOT, CLEARSNAPSHOT, VERSION, TPSTATS, FLUSH, DRAIN,
-        DECOMMISSION, MOVE, LOADBALANCE, REMOVETOKEN, REPAIR, CLEANUP, COMPACT, SCRUB,
+        DECOMMISSION, MOVE, REMOVETOKEN, REPAIR, CLEANUP, COMPACT, SCRUB,
         SETCACHECAPACITY, GETCOMPACTIONTHRESHOLD, SETCOMPACTIONTHRESHOLD, NETSTATS, CFHISTOGRAMS,
         COMPACTIONSTATS, DISABLEGOSSIP, ENABLEGOSSIP, INVALIDATEKEYCACHE, INVALIDATEROWCACHE,
         DISABLETHRIFT, ENABLETHRIFT, JOIN, SETCOMPACTIONTHROUGHPUT
@@ -100,7 +100,6 @@ public class NodeCmd
         addCmdHelp(header, "tpstats", "Print usage statistics of thread pools");
         addCmdHelp(header, "drain", "Drain the node (stop accepting writes and flush all
column families)");
         addCmdHelp(header, "decommission", "Decommission the node");
-        addCmdHelp(header, "loadbalance", "Loadbalance the node");
         addCmdHelp(header, "compactionstats", "Print statistics on compactions");
         addCmdHelp(header, "disablegossip", "Disable gossip (effectively marking the node
dead)");
         addCmdHelp(header, "enablegossip", "Reenable gossip");
@@ -553,7 +552,6 @@ public class NodeCmd
             case INFO            : nodeCmd.printInfo(System.out); break;
             case CFSTATS         : nodeCmd.printColumnFamilyStats(System.out); break;
             case DECOMMISSION    : probe.decommission(); break;
-            case LOADBALANCE     : probe.loadBalance(); break;
             case TPSTATS         : nodeCmd.printThreadPoolStats(System.out); break;
             case VERSION         : nodeCmd.printReleaseVersion(System.out); break;
             case COMPACTIONSTATS : nodeCmd.printCompactionStats(System.out); break;

Modified: cassandra/branches/cassandra-0.8/src/java/org/apache/cassandra/tools/NodeProbe.java
URL: http://svn.apache.org/viewvc/cassandra/branches/cassandra-0.8/src/java/org/apache/cassandra/tools/NodeProbe.java?rev=1091139&r1=1091138&r2=1091139&view=diff
==============================================================================
--- cassandra/branches/cassandra-0.8/src/java/org/apache/cassandra/tools/NodeProbe.java (original)
+++ cassandra/branches/cassandra-0.8/src/java/org/apache/cassandra/tools/NodeProbe.java Mon
Apr 11 17:35:42 2011
@@ -354,11 +354,6 @@ public class NodeProbe
         ssProxy.decommission();
     }
 
-    public void loadBalance() throws IOException
-    {
-        ssProxy.loadBalance();
-    }
-
     public void move(String newToken) throws IOException, InterruptedException
     {
         ssProxy.move(newToken);



Mime
View raw message