Author: rwesten
Date: Fri Jun 7 09:09:40 2013
New Revision: 1490551
URL: http://svn.apache.org/r1490551
Log:
STANBOL-1081: an other change that ensures that the context classloader is set
to the bundle classloader while initialising the OsgiSolrResourceLoader,
because the super implementation (SolrResourceLoader) inits the SPI table
during initialisation
Modified:
stanbol/trunk/commons/solr/core/src/main/java/org/apache/stanbol/commons/solr/SolrServerAdapter.java
Modified:
stanbol/trunk/commons/solr/core/src/main/java/org/apache/stanbol/commons/solr/SolrServerAdapter.java
URL:
http://svn.apache.org/viewvc/stanbol/trunk/commons/solr/core/src/main/java/org/apache/stanbol/commons/solr/SolrServerAdapter.java?rev=1490551&r1=1490550&r2=1490551&view=diff
==============================================================================
---
stanbol/trunk/commons/solr/core/src/main/java/org/apache/stanbol/commons/solr/SolrServerAdapter.java
(original)
+++
stanbol/trunk/commons/solr/core/src/main/java/org/apache/stanbol/commons/solr/SolrServerAdapter.java
Fri Jun 7 09:09:40 2013
@@ -218,12 +218,12 @@ public class SolrServerAdapter {
this.context = context;
//create a clone so that only we control who changes to the properties
serverProperties = parsedServerProperties.clone();
- SolrResourceLoader loader = new OsgiSolrResourceLoader(context,
solrDir.getAbsolutePath(),
- SolrServerAdapter.class.getClassLoader());
ClassLoader classLoader = updateContextClassLoader();
CoreContainer container;
try {
+ SolrResourceLoader loader = new OsgiSolrResourceLoader(context,
solrDir.getAbsolutePath(),
+ SolrServerAdapter.class.getClassLoader());
container = new OsgiCoreContainer(loader, context);
} finally {
Thread.currentThread().setContextClassLoader(classLoader);