I am using jboss-5.1.0.GA with j2sdk1.4.2_06.
My application is deployed successfully, but I get the error when I browse my app.
http://localhost:8080/esm/
Gives the following error, please help.
org.apache.jasper.JasperException: Unable to initialize TldLocationsCache: java.util.zip.ZipException: invalid entry CRC (expected 0x47d80677 but got 0x7815789e)
org.jboss.web.tomcat.service.jasper.TagLibCache.init(TagLibCache.java:106)
org.jboss.web.tomcat.service.jasper.TagLibCache.getLocation(TagLibCache.java:83)
org.apache.jasper.JspCompilationContext.getTldLocation(JspCompilationContext.java:549)
org.apache.jasper.compiler.Parser.parseTaglibDirective(Parser.java:428)
org.apache.jasper.compiler.Parser.parseDirective(Parser.java:491)
org.apache.jasper.compiler.Parser.parseElements(Parser.java:1438)
org.apache.jasper.compiler.Parser.parse(Parser.java:137)
org.apache.jasper.compiler.ParserController.doParse(ParserController.java:255)
org.apache.jasper.compiler.ParserController.parse(ParserController.java:103)
org.apache.jasper.compiler.Compiler.generateJava(Compiler.java:171)
org.apache.jasper.compiler.Compiler.compile(Compiler.java:333)
org.apache.jasper.compiler.Compiler.compile(Compiler.java:313)
org.apache.jasper.compiler.Compiler.compile(Compiler.java:300)
org.apache.jasper.JspCompilationContext.compile(JspCompilationContext.java:585)
org.apache.jasper.servlet.JspServletWrapper.service(JspServletWrapper.java:312)
org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:322)
org.apache.jasper.servlet.JspServlet.service(JspServlet.java:249)
javax.servlet.http.HttpServlet.service(HttpServlet.java:717)
org.jboss.web.tomcat.filters.ReplyHeaderFilter.doFilter(ReplyHeaderFilter.java:96)
root cause
org.apache.jasper.JasperException: java.util.zip.ZipException: invalid entry CRC (expected 0x47d80677 but got 0x7815789e)
org.jboss.web.tomcat.service.jasper.TagLibCache.scanJar(TagLibCache.java:343)
org.jboss.web.tomcat.service.jasper.TagLibCache.processTldsInFileSystem(TagLibCache.java:268)
org.jboss.web.tomcat.service.jasper.TagLibCache.processTldsInFileSystem(TagLibCache.java:261)
org.jboss.web.tomcat.service.jasper.TagLibCache.init(TagLibCache.java:101)
org.jboss.web.tomcat.service.jasper.TagLibCache.getLocation(TagLibCache.java:83)
org.apache.jasper.JspCompilationContext.getTldLocation(JspCompilationContext.java:549)
org.apache.jasper.compiler.Parser.parseTaglibDirective(Parser.java:428)
org.apache.jasper.compiler.Parser.parseDirective(Parser.java:491)
org.apache.jasper.compiler.Parser.parseElements(Parser.java:1438)
org.apache.jasper.compiler.Parser.parse(Parser.java:137)
org.apache.jasper.compiler.ParserController.doParse(ParserController.java:255)
org.apache.jasper.compiler.ParserController.parse(ParserController.java:103)
org.apache.jasper.compiler.Compiler.generateJava(Compiler.java:171)
org.apache.jasper.compiler.Compiler.compile(Compiler.java:333)
org.apache.jasper.compiler.Compiler.compile(Compiler.java:313)
org.apache.jasper.compiler.Compiler.compile(Compiler.java:300)
org.apache.jasper.JspCompilationContext.compile(JspCompilationContext.java:585)
org.apache.jasper.servlet.JspServletWrapper.service(JspServletWrapper.java:312)
org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:322)
org.apache.jasper.servlet.JspServlet.service(JspServlet.java:249)
javax.servlet.http.HttpServlet.service(HttpServlet.java:717)
org.jboss.web.tomcat.filters.ReplyHeaderFilter.doFilter(ReplyHeaderFilter.java:96)
root cause
java.util.zip.ZipException: invalid entry CRC (expected 0x47d80677 but got 0x7815789e)
java.util.zip.ZipInputStream.readEnd(ZipInputStream.java:381)
java.util.zip.ZipInputStream.read(ZipInputStream.java:148)
java.util.jar.JarInputStream.read(JarInputStream.java:177)
java.util.zip.ZipInputStream.closeEntry(ZipInputStream.java:92)
java.util.zip.ZipInputStream.getNextEntry(ZipInputStream.java:70)
java.util.jar.JarInputStream.getNextEntry(JarInputStream.java:118)
java.util.jar.JarInputStream.getNextJarEntry(JarInputStream.java:149)
org.jboss.web.tomcat.service.jasper.TagLibCache.scanJar(TagLibCache.java:324)
org.jboss.web.tomcat.service.jasper.TagLibCache.processTldsInFileSystem(TagLibCache.java:268)
org.jboss.web.tomcat.service.jasper.TagLibCache.processTldsInFileSystem(TagLibCache.java:261)
org.jboss.web.tomcat.service.jasper.TagLibCache.init(TagLibCache.java:101)
org.jboss.web.tomcat.service.jasper.TagLibCache.getLocation(TagLibCache.java:83)
org.apache.jasper.JspCompilationContext.getTldLocation(JspCompilationContext.java:549)
org.apache.jasper.compiler.Parser.parseTaglibDirective(Parser.java:428)
org.apache.jasper.compiler.Parser.parseDirective(Parser.java:491)
org.apache.jasper.compiler.Parser.parseElements(Parser.java:1438)
org.apache.jasper.compiler.Parser.parse(Parser.java:137)
org.apache.jasper.compiler.ParserController.doParse(ParserController.java:255)
org.apache.jasper.compiler.ParserController.parse(ParserController.java:103)
org.apache.jasper.compiler.Compiler.generateJava(Compiler.java:171)
org.apache.jasper.compiler.Compiler.compile(Compiler.java:333)
org.apache.jasper.compiler.Compiler.compile(Compiler.java:313)
org.apache.jasper.compiler.Compiler.compile(Compiler.java:300)
org.apache.jasper.JspCompilationContext.compile(JspCompilationContext.java:585)
org.apache.jasper.servlet.JspServletWrapper.service(JspServletWrapper.java:312)
org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:322)
org.apache.jasper.servlet.JspServlet.service(JspServlet.java:249)
javax.servlet.http.HttpServlet.service(HttpServlet.java:717)
org.jboss.web.tomcat.filters.ReplyHeaderFilter.doFilter(ReplyHeaderFilter.java:96)
Thanks for the answe, but even after adding, I get the error.
org.apache.jasper.JasperException: Unable to compile class for JSP:
An error occurred at line: 54 in the generated java file The method getJspApplicationContext(ServletContext) is undefined for the type JspFactory
An error occurred at line: 177 in the generated java file The metho开发者_如何学运维d _jspx_meth_bean_005fmessage_005f1(JspTag, PageContext) in the type mainMenu_jsp is not applicable for the arguments (FormTag, PageContext)
Need to add in jboss5 default/deployers/jboss.deployer/web.xml
<init-param>
<param-name>engineOptionsClass</param-name>
<param-value>
org.jboss.web.tomcat.service.jasper.JspServletOptions</param-value>
</init-param>
after add
<init-param> <param-name>engineOptionsClass</param-name>
<param-value>org.jboss.web.tomcat.tc5.jasper.JspServletOptions
</param-value>
</init-param>
My Jar file in web-inf/lib
was corrupted.
So got the exception :
org.apache.jasper.JasperException: Unable to initialize TldLocationsCache: java.util.zip.ZipException: invalid entry CRC (expected 0x47d80677 but got 0x7815789e)
To solve this :
Try extracting (-xvf) or listing (-tf) out all the jars in web-inf/lib
.
Any jar giving the zip exception while listing or extracting is the corrupted one.
精彩评论