I am working on migrating a website from Java 6, running on Weblogic 11g (10.3.5) to Java 8, running Weblogic 12c (12.1.3). I have found several issues (it helps that others on my team have tried it before, without enough success), but one seems insurmountable, and I can't find out anything about it.
One of our JSPs fails to load in the browser with a weblogic.servlet.jsp.CompilationException
, complaining that "The code of method _jspService(HttpServletRequest, HttpServletResponse) is exceeding the 65535 bytes limit." Examining the differences between the generated .java
file for the JSP in two versions of Weblogic, I see that each JSP expression is wrapped in an ExpressionInterceptor.
For example, in WebLogic 10 running Java 6, <%=user.getLanguage()%>
becomes out.print(user.getLanguage());
. In WebLogic 12 running Java 8, it becomes:
out.print(_jsp_expressionInterceptor.intercept(
String.valueOf(user.getLanguage()), pageContext,
weblogic.servlet.jsp.ExpressionInterceptor.Type.Scripting));
It seems to me that the extra few method calls - 2 method calls, about 250 times in the file - is enough to bring the _jspService
method above the 64K limit. (The method size in Java 6, based on output from javap
, is 62912 bytes, so that makes sense.)
My question is: is there any way to keep Weblogic from generating the calls to the ExpressionInterceptor
?
Thanks.
This is a known issue that has a patch for 12.1.3 & 12.1.2 Bug 17968606
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With