mirror of https://github.com/apache/lucene.git
SOLR-1449: output error log in addToClassLoader(String,FileFilter), same as addToClassLoader(String) does, when baseDir is not correct
git-svn-id: https://svn.apache.org/repos/asf/lucene/dev/trunk@1069656 13f79535-47bb-0310-9956-ffa450edef68
This commit is contained in:
parent
224d7b4ed6
commit
7972ac83ad
|
@ -131,7 +131,12 @@ public class SolrResourceLoader implements ResourceLoader
|
||||||
*/
|
*/
|
||||||
void addToClassLoader(final String baseDir, final FileFilter filter) {
|
void addToClassLoader(final String baseDir, final FileFilter filter) {
|
||||||
File base = FileUtils.resolvePath(new File(getInstanceDir()), baseDir);
|
File base = FileUtils.resolvePath(new File(getInstanceDir()), baseDir);
|
||||||
this.classLoader = replaceClassLoader(classLoader, base, filter);
|
if(base != null && base.canRead() && base.isDirectory()){
|
||||||
|
this.classLoader = replaceClassLoader(classLoader, base, filter);
|
||||||
|
}
|
||||||
|
else{
|
||||||
|
log.error("Can't find (or read) file to add to classloader: " + base);
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
|
Loading…
Reference in New Issue