title: Compilation error: org.eclipse.jdt.internal.compiler.classfmt.ClassFormatException
body: <p>I've just upgraded from Java 7 to Java 8, Tomcat 8 has a single app running inside, which seems to have no problems, but inside  <code>/var/log/tomcat8/catalina.out</code> I found the following error messages:</p>
  
  <pre><code>INFORMACIÓN: Server startup in 7681 ms
  abr 01, 2017 9:40:51 AM org.apache.jasper.compiler.JDTCompiler$1 findType
  GRAVE: Compilation error
  org.eclipse.jdt.internal.compiler.classfmt.ClassFormatException
      at org.eclipse.jdt.internal.compiler.classfmt.ClassFileReader.&lt;init&gt;(ClassFileReader.java:372)
      at org.apache.jasper.compiler.JDTCompiler$1.findType(JDTCompiler.java:210)
      at org.apache.jasper.compiler.JDTCompiler$1.findType(JDTCompiler.java:165)
      at org.eclipse.jdt.internal.compiler.lookup.LookupEnvironment.askForType(LookupEnvironment.java:109)
      at org.eclipse.jdt.internal.compiler.lookup.UnresolvedReferenceBinding.resolve(UnresolvedReferenceBinding.java:49)
      at org.eclipse.jdt.internal.compiler.lookup.BinaryTypeBinding.resolveType(BinaryTypeBinding.java:122)
      at org.eclipse.jdt.internal.compiler.lookup.LookupEnvironment.getTypeFromTypeSignature(LookupEnvironment.java:1242)
      at org.eclipse.jdt.internal.compiler.lookup.LookupEnvironment.getTypeFromVariantTypeSignature(LookupEnvironment.java:1298)
      at org.eclipse.jdt.internal.compiler.lookup.LookupEnvironment.getTypeArgumentsFromSignature(LookupEnvironment.java:1085)
      at org.eclipse.jdt.internal.compiler.lookup.LookupEnvironment.getTypeFromTypeSignature(LookupEnvironment.java:1247)
      at org.eclipse.jdt.internal.compiler.lookup.BinaryTypeBinding.createMethod(BinaryTypeBinding.java:550)
      at org.eclipse.jdt.internal.compiler.lookup.BinaryTypeBinding.createMethods(BinaryTypeBinding.java:630)
      at org.eclipse.jdt.internal.compiler.lookup.BinaryTypeBinding.cachePartsFrom(BinaryTypeBinding.java:365)
      at org.eclipse.jdt.internal.compiler.lookup.LookupEnvironment.createBinaryTypeFrom(LookupEnvironment.java:684)
      at org.eclipse.jdt.internal.compiler.lookup.LookupEnvironment.createBinaryTypeFrom(LookupEnvironment.java:663)
      at org.eclipse.jdt.internal.compiler.Compiler.accept(Compiler.java:296)
      at org.eclipse.jdt.internal.compiler.lookup.LookupEnvironment.askForType(LookupEnvironment.java:114)
      at org.eclipse.jdt.internal.compiler.lookup.UnresolvedReferenceBinding.resolve(UnresolvedReferenceBinding.java:49)
      at org.eclipse.jdt.internal.compiler.lookup.BinaryTypeBinding.resolveType(BinaryTypeBinding.java:122)
      at org.eclipse.jdt.internal.compiler.lookup.PackageBinding.getTypeOrPackage(PackageBinding.java:168)
      at org.eclipse.jdt.internal.compiler.lookup.Scope.getPackage(Scope.java:2352)
      at org.eclipse.jdt.internal.compiler.ast.ParameterizedQualifiedTypeReference.internalResolveLeafType(ParameterizedQualifiedTypeReference.java:138)
      at org.eclipse.jdt.internal.compiler.ast.ParameterizedQualifiedTypeReference.internalResolveType(ParameterizedQualifiedTypeReference.java:132)
      at org.eclipse.jdt.internal.compiler.ast.ParameterizedQualifiedTypeReference.resolveType(ParameterizedQualifiedTypeReference.java:340)
      at org.eclipse.jdt.internal.compiler.lookup.SourceTypeBinding.resolveTypeFor(SourceTypeBinding.java:1303)
      at org.eclipse.jdt.internal.compiler.lookup.SourceTypeBinding.fields(SourceTypeBinding.java:698)
      at org.eclipse.jdt.internal.compiler.lookup.SourceTypeBinding.faultInTypesForFieldsAndMethods(SourceTypeBinding.java:676)
      at org.eclipse.jdt.internal.compiler.lookup.CompilationUnitScope.faultInTypes(CompilationUnitScope.java:469)
      at org.eclipse.jdt.internal.compiler.Compiler.process(Compiler.java:756)
      at org.eclipse.jdt.internal.compiler.Compiler.compile(Compiler.java:468)
      at org.apache.jasper.compiler.JDTCompiler.generateClass(JDTCompiler.java:440)
      at org.apache.jasper.compiler.Compiler.compile(Compiler.java:361)
      at org.apache.jasper.compiler.Compiler.compile(Compiler.java:336)
      at org.apache.jasper.compiler.Compiler.compile(Compiler.java:323)
      at org.apache.jasper.JspCompilationContext.compile(JspCompilationContext.java:564)
      at org.apache.jasper.servlet.JspServletWrapper.service(JspServletWrapper.java:357)
      at org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:401)
      at org.apache.jasper.servlet.JspServlet.service(JspServlet.java:345)
      at javax.servlet.http.HttpServlet.service(HttpServlet.java:725)
      at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:291)
      at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206)
      at org.apache.catalina.core.ApplicationDispatcher.invoke(ApplicationDispatcher.java:721)
      at org.apache.catalina.core.ApplicationDispatcher.processRequest(ApplicationDispatcher.java:468)
      at org.apache.catalina.core.ApplicationDispatcher.doForward(ApplicationDispatcher.java:391)
      at org.apache.catalina.core.ApplicationDispatcher.forward(ApplicationDispatcher.java:318)
      at org.apache.catalina.core.StandardHostValve.custom(StandardHostValve.java:433)
      at org.apache.catalina.core.StandardHostValve.status(StandardHostValve.java:299)
      at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:176)
      at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:79)
      at org.apache.catalina.valves.AbstractAccessLogValve.invoke(AbstractAccessLogValve.java:610)
      at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:88)
      at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:537)
      at org.apache.coyote.http11.AbstractHttp11Processor.process(AbstractHttp11Processor.java:1081)
      at org.apache.coyote.AbstractProtocol$AbstractConnectionHandler.process(AbstractProtocol.java:658)
      at org.apache.coyote.http11.Http11NioProtocol$Http11ConnectionHandler.process(Http11NioProtocol.java:222)
      at org.apache.tomcat.util.net.NioEndpoint$SocketProcessor.doRun(NioEndpoint.java:1570)
      at org.apache.tomcat.util.net.NioEndpoint$SocketProcessor.run(NioEndpoint.java:1527)
      at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1142)
      at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:617)
      at org.apache.tomcat.util.threads.TaskThread$WrappingRunnable.run(TaskThread.java:61)
      at java.lang.Thread.run(Thread.java:745)
  
  abr 01, 2017 9:40:51 AM org.apache.jasper.compiler.JDTCompiler$1 findType
  GRAVE: Compilation error
  org.eclipse.jdt.internal.compiler.classfmt.ClassFormatException
      at org.eclipse.jdt.internal.compiler.classfmt.ClassFileReader.&lt;init&gt;(ClassFileReader.java:372)
      at org.apache.jasper.compiler.JDTCompiler$1.findType(JDTCompiler.java:210)
      at org.apache.jasper.compiler.JDTCompiler$1.findType(JDTCompiler.java:165)
      at org.eclipse.jdt.internal.compiler.lookup.LookupEnvironment.askForType(LookupEnvironment.java:109)
      at org.eclipse.jdt.internal.compiler.lookup.UnresolvedReferenceBinding.resolve(UnresolvedReferenceBinding.java:49)
      at org.eclipse.jdt.internal.compiler.lookup.BinaryTypeBinding.resolveType(BinaryTypeBinding.java:122)
      at org.eclipse.jdt.internal.compiler.lookup.PackageBinding.getTypeOrPackage(PackageBinding.java:168)
      at org.eclipse.jdt.internal.compiler.lookup.Scope.getType(Scope.java:2445)
      at org.eclipse.jdt.internal.compiler.ast.TypeDeclaration.resolve(TypeDeclaration.java:1006)
      at org.eclipse.jdt.internal.compiler.ast.TypeDeclaration.resolve(TypeDeclaration.java:1258)
      at org.eclipse.jdt.internal.compiler.ast.CompilationUnitDeclaration.resolve(CompilationUnitDeclaration.java:538)
      at org.eclipse.jdt.internal.compiler.Compiler.process(Compiler.java:763)
      at org.eclipse.jdt.internal.compiler.Compiler.compile(Compiler.java:468)
      at org.apache.jasper.compiler.JDTCompiler.generateClass(JDTCompiler.java:440)
      at org.apache.jasper.compiler.Compiler.compile(Compiler.java:361)
      at org.apache.jasper.compiler.Compiler.compile(Compiler.java:336)
      at org.apache.jasper.compiler.Compiler.compile(Compiler.java:323)
      at org.apache.jasper.JspCompilationContext.compile(JspCompilationContext.java:564)
      at org.apache.jasper.servlet.JspServletWrapper.service(JspServletWrapper.java:357)
      at org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:401)
      at org.apache.jasper.servlet.JspServlet.service(JspServlet.java:345)
      at javax.servlet.http.HttpServlet.service(HttpServlet.java:725)
      at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:291)
      at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206)
      at org.apache.catalina.core.ApplicationDispatcher.invoke(ApplicationDispatcher.java:721)
      at org.apache.catalina.core.ApplicationDispatcher.processRequest(ApplicationDispatcher.java:468)
      at org.apache.catalina.core.ApplicationDispatcher.doForward(ApplicationDispatcher.java:391)
      at org.apache.catalina.core.ApplicationDispatcher.forward(ApplicationDispatcher.java:318)
      at org.apache.catalina.core.StandardHostValve.custom(StandardHostValve.java:433)
      at org.apache.catalina.core.StandardHostValve.status(StandardHostValve.java:299)
      at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:176)
      at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:79)
      at org.apache.catalina.valves.AbstractAccessLogValve.invoke(AbstractAccessLogValve.java:610)
      at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:88)
      at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:537)
      at org.apache.coyote.http11.AbstractHttp11Processor.process(AbstractHttp11Processor.java:1081)
      at org.apache.coyote.AbstractProtocol$AbstractConnectionHandler.process(AbstractProtocol.java:658)
      at org.apache.coyote.http11.Http11NioProtocol$Http11ConnectionHandler.process(Http11NioProtocol.java:222)
      at org.apache.tomcat.util.net.NioEndpoint$SocketProcessor.doRun(NioEndpoint.java:1570)
      at org.apache.tomcat.util.net.NioEndpoint$SocketProcessor.run(NioEndpoint.java:1527)
      at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1142)
      at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:617)
      at org.apache.tomcat.util.threads.TaskThread$WrappingRunnable.run(TaskThread.java:61)
      at java.lang.Thread.run(Thread.java:745)
  </code></pre>
  
  <p>These errors were logged just after Server startup completed, but haven't appeared anymore.</p>
  
  <p>Doesn't look like the typical <code>Unsupported major.minor version 52.0</code>, but I guess it might be related to the Java upgrade, any ideas around it?</p>
  
  <p>The only WAR running inside was compiled with Java 7, but I guess Java 8 should handle that.</p>
  
  <p>Environment specifics:</p>
  
  <ul>
  <li>Apache Tomcat/8.0.14 (Debian)</li>
  <li>OpenJDK 1.8.0_121-8u121-b13-1~bpo8+1-b13</li>
  <li>Debian GNU/Linux 8.7 (jessie)</li>
  </ul>