i am trying to create a dynamic web app in Eclipse (Tomcat v7). The problem is that when i run my webapp index.jsp cannot be accessed. I can Access every other .jsp, but the index.jsp not.The next problem of course is ´that index.jsp cannot be loaded at the start of the app. I get the following message:
javax.servlet.ServletException: java.lang.NoClassDefFoundError: org/apache/jsp/index_jsp (wrong name: org/apache/jsp/Index_jsp)
org.apache.jasper.servlet.JspServlet.service(JspServlet.java:343)
javax.servlet.http.HttpServlet.service(HttpServlet.java:728)
root cause
java.lang.NoClassDefFoundError: org/apache/jsp/index_jsp (wrong name: org/apache/jsp/Index_jsp)
java.lang.ClassLoader.defineClass1(Native Method)
java.lang.ClassLoader.defineClass(Unknown Source)
java.security.SecureClassLoader.defineClass(Unknown Source)
java.net.URLClassLoader.defineClass(Unknown Source)
java.net.URLClassLoader.access$100(Unknown Source)
java.net.URLClassLoader$1.run(Unknown Source)
java.net.URLClassLoader$1.run(Unknown Source)
java.security.AccessController.doPrivileged(Native Method)
java.net.URLClassLoader.findClass(Unknown Source)
org.apache.jasper.servlet.JasperLoader.loadClass(JasperLoader.java:132)
org.apache.jasper.servlet.JasperLoader.loadClass(JasperLoader.java:63)
org.apache.jasper.servlet.JspServletWrapper.getServlet(JspServletWrapper.java:172)
org.apache.jasper.servlet.JspServletWrapper.service(JspServletWrapper.java:369)
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)
I have tried everything (the last option was to create a index.html and redirect it to the index.jsp but it didn't work). I have also tried to copy index.jsp in every folder of the app but it also didn't work.
Here is my web.xml
<?xml version="1.0" encoding="UTF-8"?>
<web-app xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns="http://java.sun.com/xml/ns/javaee" xsi:schemaLocation="http://java.sun.com/xml/ns/javaee http://java.sun.com/xml/ns/javaee/web-app_3_0.xsd" id="WebApp_ID" version="3.0">
<display-name>Test_WebApp_1</display-name>
<welcome-file-list>
<welcome-file>index.jsp</welcome-file>
</welcome-file-list>
</web-app>
I have also searched on Google, and there where some cases where the index.jsp was not loading, but the solutions didn't help me.
Does anybode has some idea ? Could this be something with Apache ? I have tried to run Version 6.0 but i could not start it because it didn't support some of the modules used in my app.
So, i am happy for any Information
Kinde regards
Semir
i have tried something else. I have exported my app as a war and deployed it on Apache. When i run my app right from Apache it works fine, and the index.jsp is being loaded. So i assume it is something in eclipse
edit : i solved it by installing the jdk develpment kit and Setting the JAVA_HOME Variable
thanks für the answers
Do you work under a sensitive case OS?
Because your error is: org/apache/jsp/index_jsp (wrong name: org/apache/jsp/Index_jsp
with an uppercase on Index_jsp.
Check your UR, check your file name...
Related
I use Windows10 Pro 32bit ENG, EclipseEE Mars, Java 8_66. If I want create a easy bean project with Spring and run it it show me a error in Windows dialog. When I enter this dialog it generated exception.
Java Virtual Machine Launcher - Error :
A JNI error has occurred, please check your installation and try it again.
I have in CLASSPATH : Apache *.jars
•commons-logging-1.2.jar
•commons-logging-1.2-javadoc.jar
Spring *.jars
•spring-aop-4.1.5.RELEASE.jar
•spring-beans-4.1.5.RELEASE.jar
•spring-context-4.1.5.RELEASE.jar
•spring-aspects-4.1.5.RELEASE.jar
•spring-context-support-4.1.5.RELEASE.jar
•spring-core-4.1.5.RELEASE.jar
•spring-web-4.1.5.RELEASE.jar
•spring-webmvc-4.1.5.RELEASE.jar
•spring-expression-4.1.5.RELEASE.jar
I have the tested Java 8_60 vs Spring 4.1.5, Java 8_66 vs Spring 4.1.5 or 4.2.2.
KlientMetaTest.java
package klient;
import org.springframework.context.ApplicationContext;
import org.springframework.context.support.ClassPathXmlApplicationContext;
import server.ServerVypis;
public class KlientMetaTest {
public static void main(String[] args) {
#SuppressWarnings("resource")
ApplicationContext context = new ClassPathXmlApplicationContext("META-INF/Beans.xml");
ServerVypis obj = (ServerVypis) context.getBean("mujSpring"); // id beanu
obj.getMessage();
}
}
ServerVypis.java
package server;
public class ServerVypis {
private String message;
public void setMessage(String message){
this.message = message; }
public void getMessage(){
System.out.println("Zde je tvuj Spring vypis : " + message); }
}
beans.xml which is in /META-INF/ folder
<?xml version="1.0" encoding="UTF-8"?>
<beans xmlns="http://www.springframework.org/schema/beans" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://www.springframework.org/schema/beans http://www.springframework.org/schema/beans/spring-beans-3.0.xsd">
<bean id="mujSpring" class="server.ServerVypis">
<property name="message" value="Vypis z \META-INF\Bean.xml"/>
</bean>
</beans>
Exception which was showing in console :
Exception in thread "main" java.lang.NoClassDefFoundError: org/springframework/context/ApplicationContext
at java.lang.Class.getDeclaredMethods0(Native Method)
at java.lang.Class.privateGetDeclaredMethods(Unknown Source)
at java.lang.Class.privateGetMethodRecursive(Unknown Source)
at java.lang.Class.getMethod0(Unknown Source)
at java.lang.Class.getMethod(Unknown Source)
at sun.launcher.LauncherHelper.validateMainClass(Unknown Source)
at sun.launcher.LauncherHelper.checkAndLoadMain(Unknown Source)
Caused by: java.lang.ClassNotFoundException: org.springframework.context.ApplicationContext
at java.net.URLClassLoader.findClass(Unknown Source)
at java.lang.ClassLoader.loadClass(Unknown Source)
at sun.misc.Launcher$AppClassLoader.loadClass(Unknown Source)
at java.lang.ClassLoader.loadClass(Unknown Source)
... 7 more
I have faced the same problem.
I made some changes in my pom.xml. Ff you are using the dependency of javax mail as well aws sdk then make sure that javax mail should be declare before the aws sdk's.
If you change the sequence then it will show the above error as it's loading jars in wrong sequence.As this worked in mine case, Hope this will work for you!
Problem solved. After I install Windows10, it broke my access to folders when I have save the external jars of frameworks.
This has been driving me nuts. When I save something, Tomcat sporadically crashes with the following error... Edit JSP or Java files. Save your work. Then maybe a 25% probability of a crash... The clue here is that it works correctly most of the time.
After it crashes, a simple server restart fixes it again.
I've Googled it to death.
I understand is has to do with saving the sessions for reload between restarts. But while developing, this is a big help. So I don't want to disable it.
I understand that it sounds like a folder permission problem. But it works fine most of the time. i.e. I can watch the folder in Explorer and see the file SESSIONS.ser appear and disappear correctly. And it usually doesn't blow up.
I have verified that the whole related Workspace folder structure is excluded from AV and Backup software.
But still... Constant crashing.
Please help. I'm out of ideas...
Thanks
Using: Eclipse Kepler, Tomcat 7.0.45, Java 1.7.0_45-b18 64 bit, Windows 7 Pro 64 bit, 16GB RAM.
Feb 11, 2014 11:00:15 AM org.apache.catalina.session.StandardManager doUnload
SEVERE: IOException while saving persisted sessions: java.io.FileNotFoundException: D:\Workspace\Tomcat\.metadata\.plugins\org.eclipse.wst.server.core\tmp0\work\Catalina\localhost\_\SESSIONS.ser (The system cannot find the path specified)
java.io.FileNotFoundException: D:\Workspace\Tomcat\.metadata\.plugins\org.eclipse.wst.server.core\tmp0\work\Catalina\localhost\_\SESSIONS.ser (The system cannot find the path specified)
at java.io.FileOutputStream.open(Native Method)
at java.io.FileOutputStream.<init>(Unknown Source)
at java.io.FileOutputStream.<init>(Unknown Source)
at org.apache.catalina.session.StandardManager.doUnload(StandardManager.java:386)
at org.apache.catalina.session.StandardManager.unload(StandardManager.java:353)
at org.apache.catalina.session.StandardManager.stopInternal(StandardManager.java:518)
at org.apache.catalina.util.LifecycleBase.stop(LifecycleBase.java:232)
at org.apache.catalina.core.StandardContext.stopInternal(StandardContext.java:5622)
at org.apache.catalina.util.LifecycleBase.stop(LifecycleBase.java:232)
at org.apache.catalina.core.StandardContext.reload(StandardContext.java:3947)
at org.apache.catalina.loader.WebappLoader.backgroundProcess(WebappLoader.java:426)
at org.apache.catalina.core.ContainerBase.backgroundProcess(ContainerBase.java:1345)
at org.apache.catalina.core.ContainerBase$ContainerBackgroundProcessor.processChildren(ContainerBase.java:1530)
at org.apache.catalina.core.ContainerBase$ContainerBackgroundProcessor.processChildren(ContainerBase.java:1540)
at org.apache.catalina.core.ContainerBase$ContainerBackgroundProcessor.processChildren(ContainerBase.java:1540)
at org.apache.catalina.core.ContainerBase$ContainerBackgroundProcessor.run(ContainerBase.java:1519)
at java.lang.Thread.run(Unknown Source)
Feb 11, 2014 11:00:15 AM org.apache.catalina.session.StandardManager stopInternal
SEVERE: Exception unloading sessions to persistent storage
java.io.FileNotFoundException: D:\Workspace\Tomcat\.metadata\.plugins\org.eclipse.wst.server.core\tmp0\work\Catalina\localhost\_\SESSIONS.ser (The system cannot find the path specified)
at java.io.FileOutputStream.open(Native Method)
at java.io.FileOutputStream.<init>(Unknown Source)
at java.io.FileOutputStream.<init>(Unknown Source)
at org.apache.catalina.session.StandardManager.doUnload(StandardManager.java:386)
at org.apache.catalina.session.StandardManager.unload(StandardManager.java:353)
at org.apache.catalina.session.StandardManager.stopInternal(StandardManager.java:518)
at org.apache.catalina.util.LifecycleBase.stop(LifecycleBase.java:232)
at org.apache.catalina.core.StandardContext.stopInternal(StandardContext.java:5622)
at org.apache.catalina.util.LifecycleBase.stop(LifecycleBase.java:232)
at org.apache.catalina.core.StandardContext.reload(StandardContext.java:3947)
at org.apache.catalina.loader.WebappLoader.backgroundProcess(WebappLoader.java:426)
at org.apache.catalina.core.ContainerBase.backgroundProcess(ContainerBase.java:1345)
at org.apache.catalina.core.ContainerBase$ContainerBackgroundProcessor.processChildren(ContainerBase.java:1530)
at org.apache.catalina.core.ContainerBase$ContainerBackgroundProcessor.processChildren(ContainerBase.java:1540)
at org.apache.catalina.core.ContainerBase$ContainerBackgroundProcessor.processChildren(ContainerBase.java:1540)
at org.apache.catalina.core.ContainerBase$ContainerBackgroundProcessor.run(ContainerBase.java:1519)
at java.lang.Thread.run(Unknown Source)
Try adding metadata-complete="true" to your web.xml and restart tomcat. It has solved another missing file problem of mine but I am still not sure why it worked for me.
<web-app xmlns="http://java.sun.com/xml/ns/javaee" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://java.sun.com/xml/ns/javaee http://java.sun.com/xml/ns/javaee/web-app_2_5.xsd"
version="2.5" metadata-complete="true">
From morning facing Exception while running struts2 apps....application was working yesterday
There's a problem in loading some struts2-jquery jar even though they exist in WEB-INF/lib
After browsing I got some solution to make change in struts.xml <!DOCTYPE ....>
like changing
<!DOCTYPE struts PUBLIC
"-//Apache Software Foundation//DTD Struts Configuration 2.3//EN"
"http://struts.apache.org/dtds/struts-2.3.dtd">
to
<!DOCTYPE struts SYSTEM "../dtds/struts-2.0.dtd">
or
<!DOCTYPE struts SYSTEM "struts-2.0.dtd">
For local referencing struts.dtd but none of these working..
Exception on console :
Unable to load configuration. - action - file:/D:/.........plugins/org.eclipse.wst.server.core/tmp0/wtpwebapps/XXXXXXXX/WEB-INF/classes/struts.xml:25:88
at com.opensymphony.xwork2.config.ConfigurationManager.getConfiguration(ConfigurationManager.java:58)
at org.apache.struts2.dispatcher.Dispatcher.init_PreloadConfiguration(Dispatcher.java:360)
at org.apache.struts2.dispatcher.Dispatcher.init(Dispatcher.java:403)
at org.apache.struts2.dispatcher.ng.InitOperations.initDispatcher(InitOperations.java:69)
at org.apache.struts2.dispatcher.ng.filter.StrutsPrepareAndExecuteFilter.init(StrutsPrepareAndExecuteFilter.java:48)
at org.apache.catalina.core.ApplicationFilterConfig.initFilter(ApplicationFilterConfig.java:273)
at org.apache.catalina.core.ApplicationFilterConfig.getFilter(ApplicationFilterConfig.java:254)
at org.apache.catalina.core.ApplicationFilterConfig.setFilterDef(ApplicationFilterConfig.java:372)
at org.apache.catalina.core.ApplicationFilterConfig.<init>(ApplicationFilterConfig.java:98)
at org.apache.catalina.core.StandardContext.filterStart(StandardContext.java:4584)
at org.apache.catalina.core.StandardContext$2.call(StandardContext.java:5262)
at org.apache.catalina.core.StandardContext$2.call(StandardContext.java:5257)
at java.util.concurrent.FutureTask$Sync.innerRun(Unknown Source)
at java.util.concurrent.FutureTask.run(Unknown Source)
at java.util.concurrent.ThreadPoolExecutor$Worker.runTask(Unknown Source)
at java.util.concurrent.ThreadPoolExecutor$Worker.run(Unknown Source)
at java.lang.Thread.run(Unknown Source)
Caused by: Error building results for action getGroups in namespace - action - file:/D:/T....plugins/org.eclipse.wst.server.core/tmp0/wtpwebapps/XXXXXXX/WEB-INF/classes/struts.xml:25:88
This has been resolved and was due to a change in Apache project publishing mechanisms.
For details :
https://issues.apache.org/jira/browse/WW-3979
I am working on a java web application using struts that someone else wrote and I was getting errors about an import that was missing in some files so I looked around the project folders and found the file among the jsp files which seemed strange. So, I copied the file into the relevant package and the errors went away. When I went to run the program again on Tomcat I got this error:
org.apache.jasper.JasperException: /index.jsp(3,55) File "/WEB-INF/struts-html.tld" not found
org.apache.jasper.compiler.DefaultErrorHandler.jspError(DefaultErrorHandler.java:41)
org.apache.jasper.compiler.ErrorDispatcher.dispatch(ErrorDispatcher.java:407)
org.apache.jasper.compiler.ErrorDispatcher.jspError(ErrorDispatcher.java:132)
org.apache.jasper.compiler.TagLibraryInfoImpl.<init>(TagLibraryInfoImpl.java:166)
org.apache.jasper.compiler.Parser.parseTaglibDirective(Parser.java:410)
org.apache.jasper.compiler.Parser.parseDirective(Parser.java:475)
org.apache.jasper.compiler.Parser.parseElements(Parser.java:1425)
org.apache.jasper.compiler.Parser.parse(Parser.java:138)
org.apache.jasper.compiler.ParserController.doParse(ParserController.java:239)
org.apache.jasper.compiler.ParserController.parse(ParserController.java:102)
org.apache.jasper.compiler.Compiler.generateJava(Compiler.java:197)
org.apache.jasper.compiler.Compiler.compile(Compiler.java:372)
org.apache.jasper.compiler.Compiler.compile(Compiler.java:352)
org.apache.jasper.compiler.Compiler.compile(Compiler.java:339)
org.apache.jasper.JspCompilationContext.compile(JspCompilationContext.java:594)
org.apache.jasper.servlet.JspServletWrapper.service(JspServletWrapper.java:344)
org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:391)
org.apache.jasper.servlet.JspServlet.service(JspServlet.java:334)
javax.servlet.http.HttpServlet.service(HttpServlet.java:722)
"/WEB-INF/struts-html.tld" still exists and hasn't been changed or moved. I decided to delete the file I moved because the program still worked without it but I still get the error and I'm not sure how I could fix this.
Edit:
So I decided to refresh the webpage and a different error showed up:
org.apache.jasper.JasperException: java.lang.ClassNotFoundException: org.apache.jsp.index_jsp
org.apache.jasper.servlet.JspServletWrapper.getServlet(JspServletWrapper.java:168)
org.apache.jasper.servlet.JspServletWrapper.service(JspServletWrapper.java:356)
org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:391)
org.apache.jasper.servlet.JspServlet.service(JspServlet.java:334)
javax.servlet.http.HttpServlet.service(HttpServlet.java:722)
root cause
java.lang.ClassNotFoundException: org.apache.jsp.index_jsp
java.net.URLClassLoader$1.run(Unknown Source)
java.security.AccessController.doPrivileged(Native Method)
java.net.URLClassLoader.findClass(Unknown Source)
org.apache.jasper.servlet.JasperLoader.loadClass(JasperLoader.java:132)
org.apache.jasper.servlet.JasperLoader.loadClass(JasperLoader.java:63)
org.apache.jasper.servlet.JspServletWrapper.getServlet(JspServletWrapper.java:162)
org.apache.jasper.servlet.JspServletWrapper.service(JspServletWrapper.java:356)
org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:391)
org.apache.jasper.servlet.JspServlet.service(JspServlet.java:334)
javax.servlet.http.HttpServlet.service(HttpServlet.java:722)
The tld (tag library) files and their locations are specified in the web.xml file.
If you need new tlds, the jsp files which are using these tlds will look first in the web.xml to find info and location of the file.
In your web.xml you need to place taglib definitions right after welcome-page definitions. It worked for me.
I am using sitemesh to decorate the pages. I am using a JSP page for this. The page worked fine until I used the <c:if> conditional tag. I have the jstl-impl-1.2.jar & sitemesh-3.0-alpha-1.jar files in the WEB-INF/lib folder. I have following tag library declarations in the jsp page:
<%# taglib uri="http://java.sun.com/jsp/jstl/core" prefix="c" %>
<%# taglib uri="http://java.sun.com/jsp/jstl/functions" prefix="fn" %>
<%# taglib uri="http://java.sun.com/jsp/jstl/fmt" prefix="fmt" %>
<%# taglib uri="http://java.sun.com/jsp/jstl/sql" prefix="sql" %>
I am using tomcat 7.0 with java 6. When I created the new dynamic web project in eclipse, I set the dynamic web module version to 2.4. The page has <c:set/> tags, they are working fine, but when I use the if conditional tag I get the following error:
javax.servlet.ServletException: java.lang.NoClassDefFoundError: javax/servlet/jsp/jstl/core/ConditionalTagSupport
org.apache.jasper.servlet.JspServlet.service(JspServlet.java:342)
javax.servlet.http.HttpServlet.service(HttpServlet.java:722)
org.sitemesh.webapp.WebAppContext.dispatch(WebAppContext.java:158)
org.sitemesh.webapp.WebAppContext.decorate(WebAppContext.java:133)
org.sitemesh.BaseSiteMeshContext.decorate(BaseSiteMeshContext.java:39)
org.sitemesh.webapp.SiteMeshFilter.postProcess(SiteMeshFilter.java:74)
org.sitemesh.webapp.contentfilter.ContentBufferingFilter.bufferAndPostProcess(ContentBufferingFilter.java:175)
org.sitemesh.webapp.contentfilter.ContentBufferingFilter.doFilter(ContentBufferingFilter.java:126)
org.sitemesh.config.ConfigurableSiteMeshFilter.doFilter(ConfigurableSiteMeshFilter.java:157)
root cause
java.lang.NoClassDefFoundError: javax/servlet/jsp/jstl/core/ConditionalTagSupport
java.lang.ClassLoader.defineClass1(Native Method)
java.lang.ClassLoader.defineClassCond(Unknown Source)
java.lang.ClassLoader.defineClass(Unknown Source)
java.security.SecureClassLoader.defineClass(Unknown Source)
org.apache.catalina.loader.WebappClassLoader.findClassInternal(WebappClassLoader.java:2820)
org.apache.catalina.loader.WebappClassLoader.findClass(WebappClassLoader.java:1150)
org.apache.catalina.loader.WebappClassLoader.loadClass(WebappClassLoader.java:1645)
org.apache.catalina.loader.WebappClassLoader.loadClass(WebappClassLoader.java:1523)
org.apache.jasper.compiler.Parser.parseCustomTag(Parser.java:1223)
org.apache.jasper.compiler.Parser.parseElements(Parser.java:1450)
org.apache.jasper.compiler.Parser.parse(Parser.java:138)
org.apache.jasper.compiler.ParserController.doParse(ParserController.java:242)
org.apache.jasper.compiler.ParserController.parse(ParserController.java:102)
org.apache.jasper.compiler.Compiler.generateJava(Compiler.java:198)
org.apache.jasper.compiler.Compiler.compile(Compiler.java:373)
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:644)
org.apache.jasper.servlet.JspServletWrapper.service(JspServletWrapper.java:358)
org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:389)
org.apache.jasper.servlet.JspServlet.service(JspServlet.java:333)
javax.servlet.http.HttpServlet.service(HttpServlet.java:722)
org.sitemesh.webapp.WebAppContext.dispatch(WebAppContext.java:158)
org.sitemesh.webapp.WebAppContext.decorate(WebAppContext.java:133)
org.sitemesh.BaseSiteMeshContext.decorate(BaseSiteMeshContext.java:39)
org.sitemesh.webapp.SiteMeshFilter.postProcess(SiteMeshFilter.java:74)
org.sitemesh.webapp.contentfilter.ContentBufferingFilter.bufferAndPostProcess(ContentBufferingFilter.java:175)
org.sitemesh.webapp.contentfilter.ContentBufferingFilter.doFilter(ContentBufferingFilter.java:126)
org.sitemesh.config.ConfigurableSiteMeshFilter.doFilter(ConfigurableSiteMeshFilter.java:157)
root cause
java.lang.ClassNotFoundException: javax.servlet.jsp.jstl.core.ConditionalTagSupport
org.apache.catalina.loader.WebappClassLoader.loadClass(WebappClassLoader.java:1678)
org.apache.catalina.loader.WebappClassLoader.loadClass(WebappClassLoader.java:1523)
java.lang.ClassLoader.defineClass1(Native Method)
java.lang.ClassLoader.defineClassCond(Unknown Source)
java.lang.ClassLoader.defineClass(Unknown Source)
java.security.SecureClassLoader.defineClass(Unknown Source)
org.apache.catalina.loader.WebappClassLoader.findClassInternal(WebappClassLoader.java:2820)
org.apache.catalina.loader.WebappClassLoader.findClass(WebappClassLoader.java:1150)
org.apache.catalina.loader.WebappClassLoader.loadClass(WebappClassLoader.java:1645)
org.apache.catalina.loader.WebappClassLoader.loadClass(WebappClassLoader.java:1523)
org.apache.jasper.compiler.Parser.parseCustomTag(Parser.java:1223)
org.apache.jasper.compiler.Parser.parseElements(Parser.java:1450)
org.apache.jasper.compiler.Parser.parse(Parser.java:138)
org.apache.jasper.compiler.ParserController.doParse(ParserController.java:242)
org.apache.jasper.compiler.ParserController.parse(ParserController.java:102)
org.apache.jasper.compiler.Compiler.generateJava(Compiler.java:198)
org.apache.jasper.compiler.Compiler.compile(Compiler.java:373)
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:644)
org.apache.jasper.servlet.JspServletWrapper.service(JspServletWrapper.java:358)
org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:389)
org.apache.jasper.servlet.JspServlet.service(JspServlet.java:333)
javax.servlet.http.HttpServlet.service(HttpServlet.java:722)
org.sitemesh.webapp.WebAppContext.dispatch(WebAppContext.java:158)
org.sitemesh.webapp.WebAppContext.decorate(WebAppContext.java:133)
org.sitemesh.BaseSiteMeshContext.decorate(BaseSiteMeshContext.java:39)
org.sitemesh.webapp.SiteMeshFilter.postProcess(SiteMeshFilter.java:74)
org.sitemesh.webapp.contentfilter.ContentBufferingFilter.bufferAndPostProcess(ContentBufferingFilter.java:175)
org.sitemesh.webapp.contentfilter.ContentBufferingFilter.doFilter(ContentBufferingFilter.java:126)
org.sitemesh.config.ConfigurableSiteMeshFilter.doFilter(ConfigurableSiteMeshFilter.java:157)
This exception suggests that the JSTL API is missing in the runtime classpath. You seem to have only the JSTL impl. I suggest to remove it and use jstl-1.2.jar instead which has both the API and impl bundled.
Further, I'd also recommend to update your web.xml root declaration to comply Servlet 3.0 spec. JSTL 1.2 requires a minimum of Servlet 2.5, so it won't work very well with a Servlet 2.4 targeted project. As Tomcat 7 is a Servlet 3.0 container and Servlet 3.0 offers a lot of new cool features over 2.5, I'd go for it.
<web-app
xmlns="http://java.sun.com/xml/ns/javaee"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://java.sun.com/xml/ns/javaee http://java.sun.com/xml/ns/javaee/web-app_3_0.xsd"
version="3.0">
Don't forget to fix your dynamic web project facet version in project's properties accordingly.
See also:
Our JSTL wiki page
maybe you must add also the javax.servlet.jsp.jstl-api-1.2.x.jar to your classpath. You're only declaring a specific implementation, without the core API.
I had the same problem and I solved in this way.
Regards,
Giacomo
JSTL lib may be missing check both jstl and servlet jars.
From Netbeans IDE
Right click on a project, then presses, libraries and add just a library
That you will fire it.