<xsl:copy-of select="document('solr:q=*:*')/*"/> results in java.lang.StringIndexOutOfBoundsException

Description

While in release 2020.05 the xsl-command

<xsl:copy-of select="document('solr:q=:')/*"/>

used to give the expected result, after the upgrade to 2020.08 this line results in the following error:

Sep 15 09:20:04 kbrandhorst tomcat9[1083]: javax.xml.transform.TransformerException: begin 0, end 17, length 5
Sep 15 09:20:04 kbrandhorst tomcat9[1083]: #011at org.apache.xpath.XPath.execute(XPath.java:365)
Sep 15 09:20:04 kbrandhorst tomcat9[1083]: #011at org.apache.xalan.templates.ElemCopyOf.execute(ElemCopyOf.java:134)
Sep 15 09:20:04 kbrandhorst tomcat9[1083]: #011at org.apache.xalan.transformer.TransformerImpl.executeChildTemplates(TransformerImpl.java:2402)
Sep 15 09:20:04 kbrandhorst tomcat9[1083]: #011at org.apache.xalan.templates.ElemIf.execute(ElemIf.java:162)
Sep 15 09:20:04 kbrandhorst tomcat9[1083]: #011at org.apache.xalan.transformer.TransformerImpl.executeChildTemplates(TransformerImpl.java:2402)
Sep 15 09:20:04 kbrandhorst tomcat9[1083]: #011at org.apache.xalan.templates.ElemLiteralResult.execute(ElemLiteralResult.java:1376)
Sep 15 09:20:04 kbrandhorst tomcat9[1083]: #011at org.apache.xalan.transformer.TransformerImpl.executeChildTemplates(TransformerImpl.java:2402)
Sep 15 09:20:04 kbrandhorst tomcat9[1083]: #011at org.apache.xalan.templates.ElemLiteralResult.execute(ElemLiteralResult.java:1376)
Sep 15 09:20:04 kbrandhorst tomcat9[1083]: #011at org.apache.xalan.transformer.TransformerImpl.executeChildTemplates(TransformerImpl.java:2402)
Sep 15 09:20:04 kbrandhorst tomcat9[1083]: #011at org.apache.xalan.templates.ElemLiteralResult.execute(ElemLiteralResult.java:1376)
Sep 15 09:20:04 kbrandhorst tomcat9[1083]: #011at org.apache.xalan.transformer.TransformerImpl.executeChildTemplates(TransformerImpl.java:2402)
Sep 15 09:20:04 kbrandhorst tomcat9[1083]: #011at org.apache.xalan.templates.ElemTemplate.execute(ElemTemplate.java:394)
Sep 15 09:20:04 kbrandhorst tomcat9[1083]: #011at org.apache.xalan.templates.ElemCallTemplate.execute(ElemCallTemplate.java:248)
Sep 15 09:20:04 kbrandhorst tomcat9[1083]: #011at org.apache.xalan.templates.ElemApplyTemplates.transformSelectedNodes(ElemApplyTemplates.java:395)
Sep 15 09:20:04 kbrandhorst tomcat9[1083]: #011at org.apache.xalan.templates.ElemApplyTemplates.execute(ElemApplyTemplates.java:178)
Sep 15 09:20:04 kbrandhorst tomcat9[1083]: #011at org.apache.xalan.transformer.TransformerImpl.executeChildTemplates(TransformerImpl.java:2402)
Sep 15 09:20:04 kbrandhorst tomcat9[1083]: #011at org.apache.xalan.transformer.TransformerImpl.applyTemplateToNode(TransformerImpl.java:2272)
Sep 15 09:20:04 kbrandhorst tomcat9[1083]: #011at org.apache.xalan.transformer.TransformerImpl.transformNode(TransformerImpl.java:1358)
Sep 15 09:20:04 kbrandhorst tomcat9[1083]: #011at org.apache.xalan.transformer.TransformerImpl.run(TransformerImpl.java:3449)
Sep 15 09:20:04 kbrandhorst tomcat9[1083]: #011at org.apache.xalan.transformer.TransformerHandlerImpl.endDocument(TransformerHandlerImpl.java:408)
Sep 15 09:20:04 kbrandhorst tomcat9[1083]: #011at org.apache.xml.serializer.ToXMLSAXHandler.endDocument(ToXMLSAXHandler.java:183)
Sep 15 09:20:04 kbrandhorst tomcat9[1083]: #011at org.apache.xalan.transformer.TransformerImpl.transformNode(TransformerImpl.java:1369)
Sep 15 09:20:04 kbrandhorst tomcat9[1083]: #011at org.apache.xalan.transformer.TransformerImpl.run(TransformerImpl.java:3449)
Sep 15 09:20:04 kbrandhorst tomcat9[1083]: #011at org.apache.xalan.transformer.TransformerHandlerImpl.endDocument(TransformerHandlerImpl.java:408)
Sep 15 09:20:04 kbrandhorst tomcat9[1083]: #011at java.xml/com.sun.org.apache.xerces.internal.parsers.AbstractSAXParser.endDocument(AbstractSAXParser.java:746)
Sep 15 09:20:04 kbrandhorst tomcat9[1083]: #011at java.xml/com.sun.org.apache.xerces.internal.impl.XMLDocumentFragmentScannerImpl.scanDocument(XMLDocumentFragmentScannerImpl.java:539)
Sep 15 09:20:04 kbrandhorst tomcat9[1083]: #011at java.xml/com.sun.org.apache.xerces.internal.parsers.XML11Configuration.parse(XML11Configuration.java:888)
Sep 15 09:20:04 kbrandhorst tomcat9[1083]: #011at java.xml/com.sun.org.apache.xerces.internal.parsers.XML11Configuration.parse(XML11Configuration.java:824)
Sep 15 09:20:04 kbrandhorst tomcat9[1083]: #011at java.xml/com.sun.org.apache.xerces.internal.parsers.XMLParser.parse(XMLParser.java:141)
Sep 15 09:20:04 kbrandhorst tomcat9[1083]: #011at java.xml/com.sun.org.apache.xerces.internal.parsers.AbstractSAXParser.parse(AbstractSAXParser.java:1216)
Sep 15 09:20:04 kbrandhorst tomcat9[1083]: #011at java.xml/com.sun.org.apache.xerces.internal.jaxp.SAXParserImpl$JAXPSAXParser.parse(SAXParserImpl.java:635)
Sep 15 09:20:04 kbrandhorst tomcat9[1083]: #011at org.mycore.common.content.transformer.MCRXSLTransformer.transform(MCRXSLTransformer.java:235)
Sep 15 09:20:04 kbrandhorst tomcat9[1083]: #011at org.mycore.common.xml.MCRLayoutService.transform(MCRLayoutService.java:198)
Sep 15 09:20:04 kbrandhorst tomcat9[1083]: #011at org.mycore.common.xml.MCRLayoutService.doLayout(MCRLayoutService.java:92)
Sep 15 09:20:04 kbrandhorst tomcat9[1083]: #011at org.mycore.frontend.servlets.MCRStaticXMLFileServlet.doGetPost(MCRStaticXMLFileServlet.java:72)
Sep 15 09:20:04 kbrandhorst tomcat9[1083]: #011at org.mycore.frontend.servlets.MCRServlet.doGet(MCRServlet.java:174)
Sep 15 09:20:04 kbrandhorst tomcat9[1083]: #011at org.mycore.frontend.servlets.MCRServlet.render(MCRServlet.java:491)
Sep 15 09:20:04 kbrandhorst tomcat9[1083]: #011at org.mycore.frontend.servlets.MCRServlet.processRenderingPhase(MCRServlet.java:456)
Sep 15 09:20:04 kbrandhorst tomcat9[1083]: #011at org.mycore.frontend.servlets.MCRServlet.doGetPost(MCRServlet.java:307)
Sep 15 09:20:04 kbrandhorst tomcat9[1083]: #011at org.mycore.frontend.servlets.MCRServlet.doGet(MCRServlet.java:146)
Sep 15 09:20:04 kbrandhorst tomcat9[1083]: #011at javax.servlet.http.HttpServlet.service(HttpServlet.java:634)
Sep 15 09:20:04 kbrandhorst tomcat9[1083]: #011at javax.servlet.http.HttpServlet.service(HttpServlet.java:741)
Sep 15 09:20:04 kbrandhorst tomcat9[1083]: #011at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:231)
Sep 15 09:20:04 kbrandhorst tomcat9[1083]: #011at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:166)
Sep 15 09:20:04 kbrandhorst tomcat9[1083]: #011at org.apache.tomcat.websocket.server.WsFilter.doFilter(WsFilter.java:53)
Sep 15 09:20:04 kbrandhorst tomcat9[1083]: #011at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:193)
Sep 15 09:20:04 kbrandhorst tomcat9[1083]: #011at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:166)
Sep 15 09:20:04 kbrandhorst tomcat9[1083]: #011at org.mycore.frontend.filter.MCRWebAppBaseFilter.doFilter(MCRWebAppBaseFilter.java:41)
Sep 15 09:20:04 kbrandhorst tomcat9[1083]: #011at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:193)
Sep 15 09:20:04 kbrandhorst tomcat9[1083]: #011at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:166)
Sep 15 09:20:04 kbrandhorst tomcat9[1083]: #011at org.mycore.frontend.filter.MCRRequestAuthenticationFilter.doFilter(MCRRequestAuthenticationFilter.java:57)
Sep 15 09:20:04 kbrandhorst tomcat9[1083]: #011at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:193)
Sep 15 09:20:04 kbrandhorst tomcat9[1083]: #011at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:166)
Sep 15 09:20:04 kbrandhorst tomcat9[1083]: #011at org.mycore.frontend.filter.MCRRequestDebugFilter.doFilter(MCRRequestDebugFilter.java:75)
Sep 15 09:20:04 kbrandhorst tomcat9[1083]: #011at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:193)
Sep 15 09:20:04 kbrandhorst tomcat9[1083]: #011at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:166)
Sep 15 09:20:04 kbrandhorst tomcat9[1083]: #011at com.google.inject.servlet.FilterChainInvocation.doFilter(FilterChainInvocation.java:89)
Sep 15 09:20:04 kbrandhorst tomcat9[1083]: #011at com.google.inject.servlet.ManagedFilterPipeline.dispatch(ManagedFilterPipeline.java:121)
Sep 15 09:20:04 kbrandhorst tomcat9[1083]: #011at com.google.inject.servlet.GuiceFilter.doFilter(GuiceFilter.java:133)
Sep 15 09:20:04 kbrandhorst tomcat9[1083]: #011at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:193)
Sep 15 09:20:04 kbrandhorst tomcat9[1083]: #011at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:166)
Sep 15 09:20:04 kbrandhorst tomcat9[1083]: #011at org.apache.logging.log4j.web.Log4jServletFilter.doFilter(Log4jServletFilter.java:71)
Sep 15 09:20:04 kbrandhorst tomcat9[1083]: #011at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:193)
Sep 15 09:20:04 kbrandhorst tomcat9[1083]: #011at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:166)
Sep 15 09:20:04 kbrandhorst tomcat9[1083]: #011at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:202)
Sep 15 09:20:04 kbrandhorst tomcat9[1083]: #011at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:96)
Sep 15 09:20:04 kbrandhorst tomcat9[1083]: #011at org.apache.catalina.authenticator.AuthenticatorBase.invoke(AuthenticatorBase.java:541)
Sep 15 09:20:04 kbrandhorst tomcat9[1083]: #011at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:139)
Sep 15 09:20:04 kbrandhorst tomcat9[1083]: #011at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:92)
Sep 15 09:20:04 kbrandhorst tomcat9[1083]: #011at org.apache.catalina.valves.AbstractAccessLogValve.invoke(AbstractAccessLogValve.java:688)
Sep 15 09:20:04 kbrandhorst tomcat9[1083]: #011at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:74)
Sep 15 09:20:04 kbrandhorst tomcat9[1083]: #011at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:343)
Sep 15 09:20:04 kbrandhorst tomcat9[1083]: #011at org.apache.coyote.http11.Http11Processor.service(Http11Processor.java:367)
Sep 15 09:20:04 kbrandhorst tomcat9[1083]: #011at org.apache.coyote.AbstractProcessorLight.process(AbstractProcessorLight.java:65)
Sep 15 09:20:04 kbrandhorst tomcat9[1083]: #011at org.apache.coyote.AbstractProtocol$ConnectionHandler.process(AbstractProtocol.java:868)
Sep 15 09:20:04 kbrandhorst tomcat9[1083]: #011at org.apache.tomcat.util.net.NioEndpoint$SocketProcessor.doRun(NioEndpoint.java:1639)
Sep 15 09:20:04 kbrandhorst tomcat9[1083]: #011at org.apache.tomcat.util.net.SocketProcessorBase.run(SocketProcessorBase.java:49)
Sep 15 09:20:04 kbrandhorst tomcat9[1083]: #011at java.base/java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1128)
Sep 15 09:20:04 kbrandhorst tomcat9[1083]: #011at java.base/java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:628)
Sep 15 09:20:04 kbrandhorst tomcat9[1083]: #011at org.apache.tomcat.util.threads.TaskThread$WrappingRunnable.run(TaskThread.java:61)
Sep 15 09:20:04 kbrandhorst tomcat9[1083]: #011at java.base/java.lang.Thread.run(Thread.java:834)
Sep 15 09:20:04 kbrandhorst tomcat9[1083]: Caused by: java.lang.StringIndexOutOfBoundsException: begin 0, end 17, length 5
Sep 15 09:20:04 kbrandhorst tomcat9[1083]: #011at java.base/java.lang.String.checkBoundsBeginEnd(String.java:3319)
Sep 15 09:20:04 kbrandhorst tomcat9[1083]: #011at java.base/java.lang.String.substring(String.java:1874)
Sep 15 09:20:04 kbrandhorst tomcat9[1083]: #011at org.mycore.solr.common.xml.MCRSolrQueryResolver.resolve(MCRSolrQueryResolver.java:58)
Sep 15 09:20:04 kbrandhorst tomcat9[1083]: #011at org.mycore.common.xml.MCRURIResolver.resolve(MCRURIResolver.java:277)
Sep 15 09:20:04 kbrandhorst tomcat9[1083]: #011at org.apache.xpath.SourceTreeManager.resolveURI(SourceTreeManager.java:127)
Sep 15 09:20:04 kbrandhorst tomcat9[1083]: #011at org.apache.xalan.templates.FuncDocument.getDoc(FuncDocument.java:237)
Sep 15 09:20:04 kbrandhorst tomcat9[1083]: #011at org.apache.xalan.templates.FuncDocument.execute(FuncDocument.java:194)
Sep 15 09:20:04 kbrandhorst tomcat9[1083]: #011at org.apache.xpath.axes.FilterExprIteratorSimple.executeFilterExpr(FilterExprIteratorSimple.java:116)
Sep 15 09:20:04 kbrandhorst tomcat9[1083]: #011at org.apache.xpath.axes.FilterExprWalker.setRoot(FilterExprWalker.java:131)
Sep 15 09:20:04 kbrandhorst tomcat9[1083]: #011at org.apache.xpath.axes.WalkingIterator.setRoot(WalkingIterator.java:157)
Sep 15 09:20:04 kbrandhorst tomcat9[1083]: #011at org.apache.xpath.axes.NodeSequence.setRoot(NodeSequence.java:265)
Sep 15 09:20:04 kbrandhorst tomcat9[1083]: #011at org.apache.xpath.axes.LocPathIterator.execute(LocPathIterator.java:212)
Sep 15 09:20:04 kbrandhorst tomcat9[1083]: #011at org.apache.xpath.XPath.execute(XPath.java:337)
Sep 15 09:20:04 kbrandhorst tomcat9[1083]: #011... 80 more

Environment

None

Assignee

Thomas Scheffler

Reporter

Kai Brandhorst

Labels

None

URL

None

External issue ID

None

Fix versions

Affects versions

Priority

Low
Configure