不可能为JSP tomcat编译类

时间:2015-04-09 09:51:08

标签: java eclipse apache java-ee tomcat7

当我开始编译任何页面jsp时,我有这个错误: 类型Rapport exception

消息无法为JSP编译类:

描述服务器遇到内部错误,导致无法完成请求。

例外

org.apache.jasper.JasperException: Unable to compile class for JSP : 

An error occurred at line: [1] in the generated java file: [C:\Users\Poste3\work\.metadata\.plugins\org.eclipse.wst.server.core\tmp0\work\Catalina\localhost\SimulateurCredit\org\apache\jsp\VueCredit_jsp.java]
The type java.util.Map$Entry cannot be resolved. It is indirectly referenced from required .class files

Stacktrace:
    org.apache.jasper.compiler.DefaultErrorHandler.javacError(DefaultErrorHandler.java:103)
    org.apache.jasper.compiler.ErrorDispatcher.javacError(ErrorDispatcher.java:366)
    org.apache.jasper.compiler.JDTCompiler.generateClass(JDTCompiler.java:468)
    org.apache.jasper.compiler.Compiler.compile(Compiler.java:378)
    org.apache.jasper.compiler.Compiler.compile(Compiler.java:353)
    org.apache.jasper.compiler.Compiler.compile(Compiler.java:340)
    org.apache.jasper.JspCompilationContext.compile(JspCompilationContext.java:646)
    org.apache.jasper.servlet.JspServletWrapper.service(JspServletWrapper.java:357)
    org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:390)
    org.apache.jasper.servlet.JspServlet.service(JspServlet.java:334)
    javax.servlet.http.HttpServlet.service(HttpServlet.java:728)
    org.apache.tomcat.websocket.server.WsFilter.doFilter(WsFilter.java:51)
    Web.controleurServlet.doGet(controleurServlet.java:23)
    javax.servlet.http.HttpServlet.service(HttpServlet.java:621)
    javax.servlet.http.HttpServlet.service(HttpServlet.java:728)
    org.apache.tomcat.websocket.server.WsFilter.doFilter(WsFilter.java:51)
Note :The complete trace of the mother cause of this error is available in the log files for Apache Tomcat / 7.0.47 .

VueCredit.jsp代码:

<%@ page language="java" contentType="text/html; charset=ISO-8859-1"
pageEncoding="ISO-8859-1"%>
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"        "http://www.w3.org/TR/html4/loose.dtd">
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1">
<title>Simulateur Credit</title>
</head>
<body>
       Test Credit
</body>
</html>

1 个答案:

答案 0 :(得分:1)

我疯了一个愚蠢的举动大声笑,我使用的是tomcat 7.0.35和JDK 8的版本所以它不兼容所以我也可以确认apache-tomcat-7.0.50或8.0.0是否支持JDK8 。 谢谢你帮我解决。