-2

warning:

javax\servlet\RequestDispatcher.class(javax\servlet:RequestDispatcher.class): major version 51 is newer than 50, the highest major version supported by this compiler. It is recommended that the compiler be upgraded. warning: javax\servlet\ServletException.class(javax\servlet:ServletException.class): major version 51 is newer than 50, the highest major version supported by this compiler. It is recommended that the compiler be upgraded. warning: javax\servlet\http\HttpServlet.class(javax\servlet\http:HttpServlet.class): major version 51 is newer than 50, the highest major version supported by this compiler. It is recommended that the compiler be upgraded. warning: javax\servlet\http\HttpServletRequest.class(javax\servlet\http:HttpServletRequest.class): major version 51 is newer than 50, the highest major version supported by this compiler. It is recommended that the compiler be upgraded. warning: javax\servlet\http\HttpServletResponse.class(javax\servlet\http:HttpServletResponse.class): major version 51 is newer than 50, the highest major version supported by this compiler. It is recommended that the compiler be upgraded. warning: javax\servlet\GenericServlet.class(javax\servlet:GenericServlet.class): major version 51 is newer than 50, the highest major version supported by this compiler. It is recommended that the compiler be upgraded. warning: javax\servlet\Servlet.class(javax\servlet:Servlet.class): major version 51 is newer than 50, the highest major version supported by this compiler. It is recommended that the compiler be upgraded. warning: javax\servlet\ServletConfig.class(javax\servlet:ServletConfig.class): major version 51 is newer than 50, the highest major version supported by this compiler. It is recommended that the compiler be upgraded. warning: javax\servlet\annotation\WebServlet.class(javax\servlet\annotation:WebServlet.class): major version 51 is newer than 50, the highest major version supported by this compiler. It is recommended that the compiler be upgraded. warning: javax\servlet\http\Cookie.class(javax\servlet\http:Cookie.class): major version 51 is newer than 50, the highest major version supported by this compiler. It is recommended that the compiler be upgraded. warning: javax\servlet\http\HttpSession.class(javax\servlet\http:HttpSession.class): major version 51 is newer than 50, the highest major version supported by this compiler. It is recommended that the compiler be upgraded. warning: javax\servlet\ServletResponse.class(javax\servlet:ServletResponse.class): major version 51 is newer than 50, the highest major version supported by this compiler. It is recommended that the compiler be upgraded. warning: javax\servlet\ServletRequest.class(javax\servlet:ServletRequest.class): major version 51 is newer than 50, the highest major version supported by this compiler. It is recommended that the compiler be upgraded. 13 warnings

Jasper
  • 7,031
  • 3
  • 35
  • 43
Taj Masindi
  • 136
  • 4
  • 10

3 Answers3

2

It is Java version issue. Just update the JDK. I believe you import this project from somewhere else. So if it is not possible to update java, try to clean it and build again. Thanks

isurujay
  • 1,386
  • 10
  • 15
1

You need to install a newer JDK. The library you are trying to use was compiled with a newer version than the one you have installed locally, thus they are not compatible.

Joachim Rohde
  • 5,915
  • 2
  • 29
  • 46
0

I was getting similar error and the issue was in pom: org.apache.maven.plugins maven-compiler-plugin 2.5.1 1.6 1.6 -Xlint:all true true

Just removed this part and it worked