Reputation: 11
We are trying to migrate our application from Java 1.6 to Java 1.8. I'm able to successfully build and deploy the EAR on WL11, but when I try to access the application, I get this error:
javax.servlet.ServletException: weblogic.servlet.jsp.CompilationException: Failed to compile JSP /jsp/login/SuperAdminProgramView.jsp
SuperAdminProgramView.jsp:24:18: The type java.util.Map$Entry cannot be resolved. It is indirectly referenced from required .class files
<%@ page import="com.gxs.ncm.mvc.model.valueobject.*" %>
Could anyone kindly let know how to resolve this issue on Web logic 11 with Java 1.8. What is the solution to make it work on Java 1.8. Does the Web logic use Java 1.8 to compile the jsp or does it use the Java version which was selected during installation of Web Logic?
Upvotes: 1
Views: 7408
Reputation: 618
When WebLogic finds a JSP without associated class or with an associated class compiled with a different WebLogic version it tries to recompile it during deployment.
This error is caused by an incompatibility between the WebLogic 11g JSP compiler and JDK 1.8.
In fact Oracle WebLogic 11g do not support JDK 1.8. See official certification matrix from Oracle site.
The support to JDK 1.8 was introduced in WebLogic Server 12.1.3 (see WLS 12.1.3 - What's New - Supported Configurations)
A workaround I've found is to pre-compile jsp pages using JDK 1.7 and the weblogic.appc utility from the same WebLogic version. This avoids recompilation during deployment and skips this specific error/incompatibility related only to the compiler. But I suggest to downgrade to JDK 1.7 or upgrade WebLogic to 12.1.3 or above, because of the missing official support from Oracle.
Upvotes: 0
Reputation: 327
For me, the solution was to use a newer ecj jar file, ecj-4.4.2.jar
Upvotes: 0
Reputation: 1859
Using Eclipse Luna it will solve your problem, since it is compatible with Java 8.
Upvotes: 0
Reputation:
Unfortunately, Eclipse Ganymede is too out-of-date to be used with Java 1.8. You'll need to update to Juno or later; ideally, you'd use Luna, since it's the later and greater Eclipse.
You can find the latest Eclipse download here, or, if you'd prefer to get Eclipse Juno or Kepler, you can get that here with instructions here1 on patching it to run with Java 8.
1 I couldn't find an official Eclipse tutorial on how to upgrade, but StackOverflow seems good enough.
Upvotes: 1