Created attachment 36758 [details] stacktrace The commit "Replace custom split(String,String) method with call to String.split by Christopher Schultz on 08/05/19 at 21:55 and git hash f7c41d120c6374a8221b684a5ad5ede3d1621ff4" introduced a bug in the version of Apache Tomcat 9.0.21 where the jsp pages using taglibs within struts tiles template are no longer being parsed properly. I got the latest git version and revert the commit (f7c41d120c6374a8221b684a5ad5ede3d1621ff4) mentioned above. The jsp pages are being parsed properly again. This is bug under jasper.jar / class org.apache.jasper.compiler.JspUtil.java
Please provide the simplest possible example (which is probably going to be a WAR file) - including source - that demonstrates this issue.
Created attachment 36760 [details] source code of the project to be tested simple project which works till version 9.0.20 and fail with the higher versions using gradle 4.10.X to generate the war to be deployed run: $ gradle clean build war
Created attachment 36761 [details] print of debug showing why it fails print of debug showing why it fails, when new split method is considering the first "/" and adding and extra "." to the package name causing the fail
Created attachment 36762 [details] print of debug showing how it was when used to work the local split method wasn't considering the the first "/" and the package name was being build properly
(In reply to Mark Thomas from comment #1) > Please provide the simplest possible example (which is probably going to be > a WAR file) - including source - that demonstrates this issue. Hi Mark, thank for the quick reply. I have attached the source code of the project (war had 4mb and was being blocked) and 2 prints while debugging. On the method JspUtil().makeJavaPackage, the split method used to not considerate the first "/" of the String. But the new refactor it does take this situation in count, causing the make a java package with "..", how you can see in the stacktrace. Stacktrace: An error occurred at line: [1] in the generated java file: [/Users/carloshager/Library/Caches/IntelliJIdea2019.2/tomcat/Unnamed_error-example/work/Catalina/localhost/error_example/org/apache/jsp/tag/meta//WEB_002dINF/customTldResource_tld/main/jsPerformanceLog_tag.java] The declared package "" does not match the expected package "org.apache.jsp.tag.meta.WEB_002dINF.customTldResource_tld.main" An error occurred at line: [9] in the generated java file: [/Users/carloshager/Library/Caches/IntelliJIdea2019.2/tomcat/Unnamed_error-example/work/Catalina/localhost/error_example/org/apache/jsp/tag/meta//WEB_002dINF/customTldResource_tld/main/jsPerformanceLog_tag.java] Syntax error on token ".", delete this token
Created attachment 36763 [details] stacktrace of the example project stacktrace of the example project
Thanks for the test case. It made it much easier to be sure that the issue was fixed. Fixed in: - master for 9.0.25 onwards