fixed shutdown of solr cores in case that more than one local core is to

be closed (this happens if webgraph is enabled and the index is dumped
using /IndexControlURLs_p.html
pull/1/head
Michael Peter Christen 11 years ago
parent 9d35455f3f
commit a7d4379ef9

@ -65,7 +65,9 @@ public class InstanceMirror {
public void disconnectEmbedded() {
mirrorConnectorCache.clear();
if (this.embeddedSolrInstance == null) return;
for (EmbeddedSolrConnector connector: this.embeddedConnectorCache.values()) connector.close();
Set<SolrConnector> connectors = new HashSet<SolrConnector>();
connectors.addAll(this.embeddedConnectorCache.values());
for (SolrConnector connector: connectors) connector.close();
this.embeddedConnectorCache.clear();
this.embeddedSolrInstance.close();
this.embeddedSolrInstance = null;

Loading…
Cancel
Save