Hi,
when I was running the the servelt class in apache tomcat 6, I was getting below error:
SEVERE: Error deploying web application directory examples
java.lang.UnsupportedClassVersionError: firstServlet : Unsupported major.minor version 51.0 (unable to load class firstServlet)
SEVERE: End event threw exception
java.lang.reflect.InvocationTargetException
at sun.reflect.GeneratedMethodAccessor33.invoke(Unknown Source)
The root cuase for this i found that:
I compiled the Java code with upper compiler (1.7) version and was trying to run it with lower version(1.5) of JVM.
Fix:
compiled the java code with 1.5 and ran with the same..Now working fine
_____________________________________________________________________________
when I was running the the servelt class in apache tomcat 6, I was getting below error:
SEVERE: Error deploying web application directory examples
java.lang.UnsupportedClassVersionError: firstServlet : Unsupported major.minor version 51.0 (unable to load class firstServlet)
SEVERE: End event threw exception
java.lang.reflect.InvocationTargetException
at sun.reflect.GeneratedMethodAccessor33.invoke(Unknown Source)
The root cuase for this i found that:
I compiled the Java code with upper compiler (1.7) version and was trying to run it with lower version(1.5) of JVM.
Fix:
compiled the java code with 1.5 and ran with the same..Now working fine
_____________________________________________________________________________
No comments:
Post a Comment