You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@lucene.apache.org by no...@apache.org on 2015/03/07 08:23:11 UTC
svn commit: r1664802 -
/lucene/dev/trunk/solr/core/src/java/org/apache/solr/core/PluginRegistry.java
Author: noble
Date: Sat Mar 7 07:23:11 2015
New Revision: 1664802
URL: http://svn.apache.org/r1664802
Log:
SOLR-7126: honor the enable.runtime.lib flag
Modified:
lucene/dev/trunk/solr/core/src/java/org/apache/solr/core/PluginRegistry.java
Modified: lucene/dev/trunk/solr/core/src/java/org/apache/solr/core/PluginRegistry.java
URL: http://svn.apache.org/viewvc/lucene/dev/trunk/solr/core/src/java/org/apache/solr/core/PluginRegistry.java?rev=1664802&r1=1664801&r2=1664802&view=diff
==============================================================================
--- lucene/dev/trunk/solr/core/src/java/org/apache/solr/core/PluginRegistry.java (original)
+++ lucene/dev/trunk/solr/core/src/java/org/apache/solr/core/PluginRegistry.java Sat Mar 7 07:23:11 2015
@@ -276,6 +276,13 @@ public class PluginRegistry<T> implement
this.pluginMeta = pluginMeta;
this.core = core;
this.resourceLoader = loader;
+ if (loader instanceof MemClassLoader) {
+ if (!"true".equals(System.getProperty("enable.runtime.lib"))) {
+ String s = "runtime library loading is not enabled, start Solr with -Denable.runtime.lib=true";
+ log.warn(s);
+ solrException = new SolrException(SolrException.ErrorCode.SERVER_ERROR, s);
+ }
+ }
}
@Override