lucene-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Rasmus Hahn <>
Subject solr-3.1.0 bug/multicore
Date Mon, 18 Apr 2011 16:35:31 GMT
Good Morning,

i noticed a small bug in your solr-3.1.0 release, but before you read any
further: This should really be a bug report, but i could not find any
possibility to submit a bug report into the jira
( If the latter should be
possible, and someone can point me to a tutorial (best with screenshots)
on where to report bugs, do not hesitate and give me a pointer. Otherwise:

Phenomenon: in a multicore solr, when using the RENAME-action for two cores,
and a solr.xml with persistent='true', the renamed core, does not get its
name persisted in solr.xml; the old name is stored (only the solr.xml file
is wrong, the in-memory-cache is correct).

Reason: in org/apache/solr/core/, when persisting the
CoreContainer, solr-3.1.0 writes the values of the private cores-map
(solr-1.4.1 wrote the keys, too). To get the name of the core, the core's
CoreDescriptor is used, but for a RENAME, the core's descriptor is not being

Fix: i changed this in the register-function of the CoreContainer class,
since it is similar to the SWAP-operation that does a similar thing.


Index: solr/src/java/org/apache/solr/core/
--- solr/src/java/org/apache/solr/core/
(revision 1094545)
+++ solr/src/java/org/apache/solr/core/       (working copy)
@@ -381,7 +381,12 @@
     SolrCore old = null;
     synchronized (cores) {
       old = cores.put(name, core);
+      /*
+       * set both the name of the descriptor and the name of the
+       * core, since the descriptors name is used for persisting.
+       */
+      core.getCoreDescriptor ().name = name;

Best Regards - Rasmus

To unsubscribe, e-mail:
For additional commands, e-mail:

View raw message