public class MiniSolrCloudCluster extends Object
| Constructor and Description |
|---|
MiniSolrCloudCluster(int numServers,
String hostContext,
File solrXml,
SortedMap<org.eclipse.jetty.servlet.ServletHolder,String> extraServlets,
SortedMap<Class,String> extraRequestFilters)
"Mini" SolrCloud cluster to be used for testing
|
| Modifier and Type | Method and Description |
|---|---|
List<org.apache.solr.client.solrj.embedded.JettySolrRunner> |
getJettySolrRunners() |
ZkTestServer |
getZkServer() |
void |
shutdown()
Shut down the cluster, including all Solr nodes and ZooKeeper
|
org.apache.solr.client.solrj.embedded.JettySolrRunner |
startJettySolrRunner(String hostContext,
SortedMap<org.eclipse.jetty.servlet.ServletHolder,String> extraServlets,
SortedMap<Class,String> extraRequestFilters)
Start a new Solr instance
|
org.apache.solr.client.solrj.embedded.JettySolrRunner |
stopJettySolrRunner(int index)
Stop a Solr instance
|
public MiniSolrCloudCluster(int numServers,
String hostContext,
File solrXml,
SortedMap<org.eclipse.jetty.servlet.ServletHolder,String> extraServlets,
SortedMap<Class,String> extraRequestFilters)
throws Exception
numServers - number of Solr servers to starthostContext - context path of Solr servers used by JettysolrXml - solr.xml file to be uploaded to ZooKeeperextraServlets - Extra servlets to be started by JettyextraRequestFilters - extra filters to be started by JettyExceptionpublic ZkTestServer getZkServer()
public List<org.apache.solr.client.solrj.embedded.JettySolrRunner> getJettySolrRunners()
public org.apache.solr.client.solrj.embedded.JettySolrRunner startJettySolrRunner(String hostContext, SortedMap<org.eclipse.jetty.servlet.ServletHolder,String> extraServlets, SortedMap<Class,String> extraRequestFilters) throws Exception
hostContext - context path of Solr servers used by JettyextraServlets - Extra servlets to be started by JettyextraRequestFilters - extra filters to be started by JettyExceptionpublic org.apache.solr.client.solrj.embedded.JettySolrRunner stopJettySolrRunner(int index)
throws Exception
index - the index of node in collection returned by getJettySolrRunners()ExceptionCopyright © 2000-2015 Apache Software Foundation. All Rights Reserved.