org.apache.solr.cloud
Class Assign

java.lang.Object
  extended by org.apache.solr.cloud.Assign

public class Assign
extends Object


Constructor Summary
Assign()
           
 
Method Summary
static String assignNode(String collection, ClusterState state)
           
static String assignShard(String collection, ClusterState state, Integer numShards)
          Assign a new unique id up to slices count - then add replicas evenly.
static ArrayList<org.apache.solr.cloud.Assign.Node> getNodesForNewShard(ClusterState clusterState, String collectionName, int numSlices, int maxShardsPerNode, int repFactor, String createNodeSetStr)
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

Assign

public Assign()
Method Detail

assignNode

public static String assignNode(String collection,
                                ClusterState state)

assignShard

public static String assignShard(String collection,
                                 ClusterState state,
                                 Integer numShards)
Assign a new unique id up to slices count - then add replicas evenly.

Returns:
the assigned shard id

getNodesForNewShard

public static ArrayList<org.apache.solr.cloud.Assign.Node> getNodesForNewShard(ClusterState clusterState,
                                                                               String collectionName,
                                                                               int numSlices,
                                                                               int maxShardsPerNode,
                                                                               int repFactor,
                                                                               String createNodeSetStr)


Copyright © 2000-2014 Apache Software Foundation. All Rights Reserved.