uschindler commented on code in PR #962:
URL: https://github.com/apache/solr/pull/962#discussion_r951526611
##########
solr/core/src/java/org/apache/solr/handler/component/QueryElevationComponent.java:
##########
@@ -376,10 +377,12 @@ protected long getConfigVersion(SolrCore core) {
*
* @return The loaded {@link ElevationProvider}; not null.
*/
- private ElevationProvider loadElevationProvider(SolrCore core) throws
Exception {
- XmlConfigFile cfg;
+ private ElevationProvider loadElevationProvider(SolrCore core) throws
IOException, SAXException {
+ InputStream inputStream = null;
+ Document xmlDocument;
try {
- cfg = new XmlConfigFile(core.getResourceLoader(), configFileName);
+ inputStream = core.getResourceLoader().openResource(configFileName);
+ xmlDocument = SafeXMLParsing.parseUntrustedXML(log, inputStream);
Review Comment:
Yes, i think that's the way to go. parseConfigXML is for stuff that is part
of Solr's config. parseUntrustedXML is for stuff coming over the network like a
POSTed document.
As all Solr config files supoort xinclude, it should also be supported for
elevantion.xml
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]