记录一次tomcat问题排查记录:org.apache.tomcat.util.bcel.classfile.ClassFormatException: Invalid byte tag in constant pool: 19
最近项目升级jdk,从jdk7 升级到 jdk8,本地已经自测完成了,需要部署到测试环境,测试环境已经装好 jdk8 了,但是tomcat 的版本还是 7。不过,据我之前了解,tomcat7是可以运行JDK8编译的web工程的,只要tomcat的运行环境的JDK是1.8即可。但是不能有比JDK1.8还要新的特性。所以最终决定不升级 tomcat 版本。 等我把项目部署到 测试环境 tomcat 下后,项目是可以跑起来的且能正常运行,但是在项目启动过程中,报了一堆错: SEVERE: Unable to process Jar entry [module-info.class] from Jar [jar:file:/home/.......(中间省略)....../WEB-INF/lib/jakarta.ws.rs-api-2.1.5.jar!/] for annotations org.apache.tomcat.util.bcel.classfile.ClassFormatException: Invalid byte tag in constant pool: 19 at org.apache.tomcat.util.bcel.classfile.Constant.readConstant(Constant.java:136) at org.apache.tomcat