Permalink
Browse files

added MySQL to rebalance list.

  • Loading branch information...
baepiff committed Mar 19, 2012
1 parent 68fca81 commit 30f2b230198835c36dc97e9ad1ccca1735be51ee
Showing with 6 additions and 4 deletions.
  1. +6 −4 src/java/voldemort/utils/RebalanceUtils.java
@@ -28,10 +28,10 @@
import java.util.LinkedHashMap;
import java.util.List;
import java.util.Map;
+import java.util.Map.Entry;
import java.util.Random;
import java.util.Set;
import java.util.TreeMap;
-import java.util.Map.Entry;
import java.util.concurrent.ExecutorService;
import java.util.concurrent.Executors;
import java.util.concurrent.ThreadFactory;
@@ -55,6 +55,7 @@
import voldemort.store.StoreDefinition;
import voldemort.store.bdb.BdbStorageConfiguration;
import voldemort.store.metadata.MetadataStore.VoldemortState;
+import voldemort.store.mysql.MysqlStorageConfiguration;
import voldemort.store.readonly.ReadOnlyStorageConfiguration;
import voldemort.store.readonly.ReadOnlyStorageFormat;
import voldemort.versioning.Occurred;
@@ -74,7 +75,8 @@
private static Logger logger = Logger.getLogger(RebalanceUtils.class);
- public final static List<String> canRebalanceList = Arrays.asList(BdbStorageConfiguration.TYPE_NAME,
+ public final static List<String> canRebalanceList = Arrays.asList(MysqlStorageConfiguration.TYPE_NAME,
+ BdbStorageConfiguration.TYPE_NAME,
ReadOnlyStorageConfiguration.TYPE_NAME);
public final static String initialClusterFileName = "initial-cluster.xml";
@@ -697,8 +699,8 @@ public static Cluster createUpdatedCluster(Cluster currentCluster,
stealerNode = RebalanceUtils.addPartitionToNode(stealerNode, donatedPartition);
// Sort the nodes
- updatedCluster = updateCluster(updatedCluster, Lists.newArrayList(donorNode,
- stealerNode));
+ updatedCluster = updateCluster(updatedCluster,
+ Lists.newArrayList(donorNode, stealerNode));
}

0 comments on commit 30f2b23

Please sign in to comment.