lucene-solr-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From no...@apache.org
Subject svn commit: r788582 - in /lucene/solr/trunk/src/java/org/apache/solr/core: SolrConfig.java SolrCore.java
Date Fri, 26 Jun 2009 05:34:24 GMT
Author: noble
Date: Fri Jun 26 05:34:24 2009
New Revision: 788582

URL: http://svn.apache.org/viewvc?rev=788582&view=rev
Log:
SOLR-1198

Modified:
    lucene/solr/trunk/src/java/org/apache/solr/core/SolrConfig.java
    lucene/solr/trunk/src/java/org/apache/solr/core/SolrCore.java

Modified: lucene/solr/trunk/src/java/org/apache/solr/core/SolrConfig.java
URL: http://svn.apache.org/viewvc/lucene/solr/trunk/src/java/org/apache/solr/core/SolrConfig.java?rev=788582&r1=788581&r2=788582&view=diff
==============================================================================
--- lucene/solr/trunk/src/java/org/apache/solr/core/SolrConfig.java (original)
+++ lucene/solr/trunk/src/java/org/apache/solr/core/SolrConfig.java Fri Jun 26 05:34:24 2009
@@ -151,6 +151,7 @@
     fieldValueCacheConfig = conf;
     unlockOnStartup = getBool("mainIndex/unlockOnStartup", false);
     useColdSearcher = getBool("query/useColdSearcher",false);
+    dataDir = get("dataDir", null);
 
     userCacheConfigs = CacheConfig.getMultipleConfigs(this, "query/cache");
 
@@ -303,6 +304,7 @@
   public final int maxWarmingSearchers;
   public final boolean unlockOnStartup;
   public final boolean useColdSearcher;
+  protected String dataDir;
   
   //JMX configuration
   public final JmxConfiguration jmxConfig;
@@ -537,4 +539,6 @@
   public List<PluginInfo> getHighlightingFormatterInfo() { return highlightingFormatterInfo;
}
 
   public List<PluginInfo> getHighlightingFragmenterInfo() { return highlightingFragmenterInfo;
}
+
+  public String getDataDir() { return dataDir; }
 }

Modified: lucene/solr/trunk/src/java/org/apache/solr/core/SolrCore.java
URL: http://svn.apache.org/viewvc/lucene/solr/trunk/src/java/org/apache/solr/core/SolrCore.java?rev=788582&r1=788581&r2=788582&view=diff
==============================================================================
--- lucene/solr/trunk/src/java/org/apache/solr/core/SolrCore.java (original)
+++ lucene/solr/trunk/src/java/org/apache/solr/core/SolrCore.java Fri Jun 26 05:34:24 2009
@@ -492,8 +492,10 @@
     coreDescriptor = cd;
     this.setName( name );
     resourceLoader = config.getResourceLoader();
-    if (dataDir == null)
-      dataDir = config.get("dataDir",cd.getDataDir());
+    if (dataDir == null){
+      dataDir =  config.getDataDir();
+      if(dataDir == null) dataDir = cd.getDataDir();
+    }
 
     dataDir = SolrResourceLoader.normalizeDir(dataDir);
 



Mime
View raw message