This week's book giveaway is in the Kotlin forum.
We're giving away four copies of Kotlin in Action and have Dmitry Jemerov & Svetlana Isakova on-line!
See this thread for details.
Win a copy of Kotlin in Action this week in the Kotlin forum!
  • Post Reply Bookmark Topic Watch Topic
  • New Topic

servlets in myeclipse  RSS feed

 
Sachitra Samarakoon
Greenhorn
Posts: 4
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I wrote a small EE application using MyEclipse, and when it runs it throws a runtime exception saying UnsupportedClassVersionError for the Servlets used in the application.
So, what should I do to prevent that and to make it work??
 
Santhosh Kumar
Ranch Hand
Posts: 242
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
UnsupportedClassVersionError is thrown when the major/minor version of the .class file cannot be supported by the JVM runtime.

In practical, this means you compiled your classes higher version of Java and trying run in lower version of it.

Try to findout which version of Java the MyEclipse is using to compile the Servlet and then you run the Servlet container in same version.

Other option is change the MyEclipse java library version to match with the Servlet Runtime container one.
 
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!