mirror of https://github.com/apache/lucene.git
SOLR-8766: Remove support for admin/gettableFiles as well
This commit is contained in:
parent
4cc9ad44df
commit
dcb7a882b6
|
@ -405,7 +405,8 @@ Other Changes
|
|||
* SOLR-8736: schema GET operations on fields, dynamicFields, fieldTypes, copyField are
|
||||
reimplemented as a part of the bulk API with less details (noble)
|
||||
|
||||
* SOLR-8766 : deprecated <admin> tag in solrconfig.xml is removed (noble)
|
||||
* SOLR-8766: Remove deprecated <admin> tag in solrconfig.xml and support for admin/gettableFiles
|
||||
(noble, Jason Gerlowski, Varun Thacker)
|
||||
|
||||
================== 5.5.1 ==================
|
||||
|
||||
|
|
|
@ -726,9 +726,6 @@ public final class SolrCore implements SolrInfoMBean, Closeable {
|
|||
reqHandlers = new RequestHandlers(this);
|
||||
reqHandlers.initHandlersFromConfig(solrConfig);
|
||||
|
||||
// Handle things that should eventually go away
|
||||
initDeprecatedSupport();
|
||||
|
||||
statsCache = initStatsCache();
|
||||
|
||||
// cause the executor to stall so firstSearcher events won't fire
|
||||
|
@ -2269,54 +2266,6 @@ public final class SolrCore implements SolrInfoMBean, Closeable {
|
|||
return valueSourceParsers.get(parserName);
|
||||
}
|
||||
|
||||
/**
|
||||
* Manage anything that should be taken care of in case configs change
|
||||
*/
|
||||
private void initDeprecatedSupport()
|
||||
{
|
||||
// TODO -- this should be removed in deprecation release...
|
||||
String gettable = solrConfig.get("admin/gettableFiles", null );
|
||||
if( gettable != null ) {
|
||||
log.warn(
|
||||
"solrconfig.xml uses deprecated <admin/gettableFiles>, Please "+
|
||||
"update your config to use the ShowFileRequestHandler." );
|
||||
if( getRequestHandler( "/admin/file" ) == null ) {
|
||||
NamedList<String> invariants = new NamedList<>();
|
||||
|
||||
// Hide everything...
|
||||
Set<String> hide = new HashSet<>();
|
||||
|
||||
for (String file : solrConfig.getResourceLoader().listConfigDir()) {
|
||||
hide.add(file.toUpperCase(Locale.ROOT));
|
||||
}
|
||||
|
||||
// except the "gettable" list
|
||||
StringTokenizer st = new StringTokenizer( gettable );
|
||||
while( st.hasMoreTokens() ) {
|
||||
hide.remove( st.nextToken().toUpperCase(Locale.ROOT) );
|
||||
}
|
||||
for( String s : hide ) {
|
||||
invariants.add( ShowFileRequestHandler.HIDDEN, s );
|
||||
}
|
||||
|
||||
NamedList<Object> args = new NamedList<>();
|
||||
args.add( "invariants", invariants );
|
||||
ShowFileRequestHandler handler = new ShowFileRequestHandler();
|
||||
handler.init( args );
|
||||
reqHandlers.register("/admin/file", handler);
|
||||
|
||||
log.warn( "adding ShowFileRequestHandler with hidden files: "+hide );
|
||||
}
|
||||
}
|
||||
|
||||
String facetSort = solrConfig.get("//bool[@name='facet.sort']", null);
|
||||
if (facetSort != null) {
|
||||
log.warn(
|
||||
"solrconfig.xml uses deprecated <bool name='facet.sort'>. Please "+
|
||||
"update your config to use <string name='facet.sort'>.");
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* Creates and initializes a RestManager based on configuration args in solrconfig.xml.
|
||||
* RestManager provides basic storage support for managed resource data, such as to
|
||||
|
|
Loading…
Reference in New Issue