mirror of https://github.com/apache/lucene.git
test-related: move constructors together, log core container creation for all
git-svn-id: https://svn.apache.org/repos/asf/lucene/dev/trunk@1023545 13f79535-47bb-0310-9956-ffa450edef68
This commit is contained in:
parent
87489d797c
commit
80f95a16e0
|
@ -85,12 +85,42 @@ public class CoreContainer
|
|||
private SolrZkServer zkServer;
|
||||
|
||||
private String zkHost;
|
||||
|
||||
public CoreContainer() {
|
||||
solrHome = SolrResourceLoader.locateSolrHome();
|
||||
|
||||
{
|
||||
log.info("New CoreContainer: solrHome=" + solrHome + " instance="+System.identityHashCode(this));
|
||||
}
|
||||
|
||||
|
||||
public CoreContainer() {
|
||||
solrHome = SolrResourceLoader.locateSolrHome();
|
||||
}
|
||||
|
||||
/**
|
||||
* Initalize CoreContainer directly from the constructor
|
||||
*
|
||||
* @param dir
|
||||
* @param configFile
|
||||
* @throws ParserConfigurationException
|
||||
* @throws IOException
|
||||
* @throws SAXException
|
||||
*/
|
||||
public CoreContainer(String dir, File configFile) throws ParserConfigurationException, IOException, SAXException
|
||||
{
|
||||
this.load(dir, configFile);
|
||||
}
|
||||
|
||||
/**
|
||||
* Minimal CoreContainer constructor.
|
||||
* @param loader the CoreContainer resource loader
|
||||
*/
|
||||
public CoreContainer(SolrResourceLoader loader) {
|
||||
this.loader = loader;
|
||||
this.solrHome = loader.getInstanceDir();
|
||||
}
|
||||
|
||||
public CoreContainer(String solrHome) {
|
||||
this.solrHome = solrHome;
|
||||
}
|
||||
|
||||
private void initZooKeeper(String zkHost, int zkClientTimeout) {
|
||||
// if zkHost sys property is not set, we are not using ZooKeeper
|
||||
String zookeeperHost;
|
||||
|
@ -245,32 +275,7 @@ public class CoreContainer
|
|||
return p;
|
||||
}
|
||||
|
||||
/**
|
||||
* Initalize CoreContainer directly from the constructor
|
||||
*
|
||||
* @param dir
|
||||
* @param configFile
|
||||
* @throws ParserConfigurationException
|
||||
* @throws IOException
|
||||
* @throws SAXException
|
||||
*/
|
||||
public CoreContainer(String dir, File configFile) throws ParserConfigurationException, IOException, SAXException
|
||||
{
|
||||
this.load(dir, configFile);
|
||||
}
|
||||
|
||||
/**
|
||||
* Minimal CoreContainer constructor.
|
||||
* @param loader the CoreContainer resource loader
|
||||
*/
|
||||
public CoreContainer(SolrResourceLoader loader) {
|
||||
this.loader = loader;
|
||||
this.solrHome = loader.getInstanceDir();
|
||||
}
|
||||
|
||||
public CoreContainer(String solrHome) {
|
||||
this.solrHome = solrHome;
|
||||
}
|
||||
|
||||
//-------------------------------------------------------------------
|
||||
// Initialization / Cleanup
|
||||
|
|
Loading…
Reference in New Issue