javax.servlet.error.exception: javax.servlet.ServletException: java.lang.NoClassDefFoundError: org/apache/jasper/runtime/JspSourceImports - eclipse

I have problem to run my apps using Tomcat 7. I got this error:
javax.servlet.error.exception: javax.servlet.ServletException: java.lang.NoClassDefFoundError: org/apache/jasper/runtime/JspSourceImports
But when I run using Tomcat 8, it works fine. I need to use Tomcat 7 because I want to run the Tomcat from Eclipse Helios, and Eclipse Helios does not support Tomcat 8.
I do not know how to fix this. Appreciate your help.

Related

Error processing request:Failed to link com/eaio/uuid/UUID

I am using jboss eap 7 and the uuid library eaio and run my application displays the following message:
Stack Trace:
org.jboss.resteasy.spi.UnhandledException: java.lang.NoClassDefFoundError: Failed to link com/eaio/uuid/UUID (Module "deployment.*-dtoEAR.ear.****-dto.war:main" from Service Module Loader): org/omg/CORBA/portable/IDLEntity**
With jboss eap 6 that does not happen.
I think the issue is with inbuilt modules provided by JBoss EAP 7. JBoss 6 provides /org/jacorb/main/jacorb-2.3.2-redhat-2.jar module which has org/omg/CORBA/portable/IDLEntity class file.
But in JBoss EAP 7, IDLEntity is provided by module /javax/orb/api/main/openjdk-orb-8.1.2.Final-redhat-00001.jar. Because of which your application is able to run on JBoss 6 but not on JBoss 7.
Try adding /org/jacorb/main/jacorb-2.3.2-redhat-2.jar module to your JBoss EAP 7 modules. It should resolve your issue.

error in struts2 project related to struts2 core jar

I have added all the required jars for struts project but while running the project on tomcat v8 i am getting this error
SEVERE: Exception starting filter struts
java.nio.file.InvalidPathException: Illegal char <:> at index 3: jar:file:\C:\Users\RITESH\eclipse-workspace\.metadata\.plugins\org.eclipse.wst.server.core\tmp1\wtpwebapps\StrutsLoginDemoApp\WEB-INF\lib\struts2-core-2.3.1.1.jar
at java.base/sun.nio.fs.WindowsPathParser.normalize(Unknown Source)
using windows 10 and struts 2.3.1.1 jars on eclipse Oxygen version. Has someone faced this issue already? I am guessing it's related to the extra ":\" that is being added in the filepath,but it it's inside the jar. How can i fix this?

java.lang.UnsupportedClassVersionError: org/openbravo/base/ConnectionProviderContextListener : Unsupported major.minor version 52.0

I am using Eclipse Indigo running on Ubuntu and I am trying to set up a Tomcat server following the last part of this guide:
http://wiki.openbravo.com/wiki/How_to_setup_Eclipse_IDE
My problem is that when I try to boot the Tomcat server I get this error (Server Tomcat v6.0 Server at localhost failed to start.):
My console looks like this:
Caused by: java.lang.UnsupportedClassVersionError: org/openbravo/base/ConnectionProviderContextListener : Unsupported major.minor version 52.0 (no puedo cargar clase org.openbravo.base.ConnectionProviderContextListener)
at org.apache.catalina.loader.WebappClassLoader.findClassInternal(WebappClassLoader.java:2822)
at org.apache.catalina.loader.WebappClassLoader.findClass(WebappClassLoader.java:1159)
at org.apache.catalina.loader.WebappClassLoader.loadClass(WebappClassLoader.java:1647)
at org.apache.catalina.loader.WebappClassLoader.loadClass(WebappClassLoader.java:1526)
at org.apache.catalina.startup.WebAnnotationSet.loadClassAnnotation(WebAnnotationSet.java:145)
at org.apache.catalina.startup.WebAnnotationSet.loadApplicationListenerAnnotations(WebAnnotationSet.java:73)
at org.apache.catalina.startup.WebAnnotationSet.loadApplicationAnnotations(WebAnnotationSet.java:56)
at org.apache.catalina.startup.ContextConfig.applicationAnnotationsConfig(ContextConfig.java:297)
at org.apache.catalina.startup.ContextConfig.start(ContextConfig.java:1078)
at org.apache.catalina.startup.ContextConfig.lifecycleEvent(ContextConfig.java:261)
at org.apache.catalina.util.LifecycleSupport.fireLifecycleEvent(LifecycleSupport.java:142)
at org.apache.catalina.core.StandardContext.start(StandardContext.java:4611)
at org.apache.catalina.core.ContainerBase.start(ContainerBase.java:1053)
at org.apache.catalina.core.StandardHost.start(StandardHost.java:840)
at org.apache.catalina.core.ContainerBase.start(ContainerBase.java:1053)
at org.apache.catalina.core.StandardEngine.start(StandardEngine.java:463)
at org.apache.catalina.core.StandardService.start(StandardService.java:525)
at org.apache.catalina.core.StandardServer.start(StandardServer.java:754)
at org.apache.catalina.startup.Catalina.start(Catalina.java:595)
... 6 more
What can I do? I tryed adding tomcat-juli.jar to my server classpath, which is the main solution I have found but it didn't work.
Thanks in advance.
EDIT:
Thanks to the answer Tomcat starts but does not make the resource available.
There are compilation errors in the Openbravo projects as well.
Eclipse Openbravo Project
Resource not available at localhost:8080/openbravo/
Tomcat Configuration in Eclipse
2nd EDIT:
Deploy Tree
Update your JDK version. The classes were probably compiled in a JDK version higher to yours.
Edit: Probably it is JDK/JRE 8.

icefaces project deployment error : org.apache.catalina.LifecycleException: java.lang.NoSuchFieldError: SKIP_ITERATION

I'm trying to make new icefaces project which generated using: ICEfaces 3.3.0 project integration for Eclipse.
I didn't modify anything on the project. but when i try to run on the server, i got an error:
cannot Deploy MyProject
Deployment Error for module: MyProject:
Exception while loading the app : java.lang.Exception:
java.lang.IllegalStateException: ContainerBase.addChild:
start: org.apache.catalina.LifecycleException:
java.lang.NoSuchFieldError: SKIP_ITERATION
before that, I'm using ICEfaces 3.2.0 project integration for Eclipse and no problem.
I'm using Eclipse Indigo, GlassFish server 3, Mojarra 2.1.6
Thanks before
java.lang.NoSuchFieldError: SKIP_ITERATION
As per the javadoc, that field was added in JSF 2.1.
So, this error suggests that your webapp's runtime classpath is polluted with a JSF 2.0 API JAR file. Perhaps in the /WEB-INF/lib? Get rid of it. Glassfish already ships with JSF bundled, you don't necessarily need to supply your own. Or, from the other side on, this can also happen if you deploy to an ancient Glassfish instance which bundles JSF 2.0 and JSF 2.1 was actually bundled in your webapp in an attempt to upgrade it. If so, then you should edited the Glassfish config file sun-web.xml or glassfish-web.xml, depending on GF version. See for detail the answer to this related question: How to update Mojarra version in GlassFish

Tomcat 7 Start up problem in Eclispse for maven project

I m getting this intermittent problem in eclipse, when i try to run a maven project in tomcat
Details are as follows :
Eclipse version : 3.6
Maven version : 2.2.1
Tomcat version : 7
Error log :
java.lang.ClassNotFoundException: org.springframework.web.context.ContextLoaderListener
at org.apache.catalina.loader.WebappClassLoader.loadClass(WebappClassLoader.java:1362)
at org.apache.catalina.loader.WebappClassLoader.loadClass(WebappClassLoader.java:1208)
at org.apache.catalina.core.StandardContext.listenerStart(StandardContext.java:3712)
at org.apache.catalina.core.StandardContext.start(StandardContext.java:4216)
at org.apache.catalina.core.ContainerBase.start(ContainerBase.java:1014)
at org.apache.catalina.core.StandardHost.start(StandardHost.java:736)
at org.apache.catalina.core.ContainerBase.start(ContainerBase.java:1014)
at org.apache.catalina.core.StandardEngine.start(StandardEngine.java:443)
at org.apache.catalina.core.StandardService.start(StandardService.java:448)
at org.apache.catalina.core.StandardServer.start(StandardServer.java:700)
at org.apache.catalina.startup.Catalina.start(Catalina.java:552)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
at java.lang.reflect.Method.invoke(Method.java:597)
at org.apache.catalina.startup.Bootstrap.start(Bootstrap.java:295)
at org.apache.catalina.startup.Bootstrap.main(Bootstrap.java:433)
Deleting and Recreating the server solves the problem, but still i would like to know why this error is created.
This error usually occurs when Spring misses a jar file on the classpath. The main reason for this is that Eclipse not always deploys a project correctly to its Tomcat server. Instead of deleting the server, you can also clean the server and redeploy the application.
Thanks for your reply. Well my problem was fixed by doing a mvn eclipse:clean eclipse:eclipse
I encountered the same error
I added my spring library in deployment assembly and build path of the project.
I think your server did not detect the library and restarting it made the server check for the build paths.