Unable to process Jar entry [module-info.class] from Jar的问题解决

Unable to process Jar entry [module-info.class] from Jar的问题解决UnabletoprocessJarentry[module-info.class]fromJar的问题解决背景解决办法背景在使用Eclipse进行SpringBoot应用开发时,如果项目启动是RunAs->RunOnServer方式运行就会报类似于UnabletoprocessJarentry[module-info.class]fromJar的错误…

大家好,又见面了,我是你们的朋友全栈君。如果您正在找激活码,请点击查看最新教程,关注关注公众号 “全栈程序员社区” 获取激活教程,可能之前旧版本教程已经失效.最新Idea2022.1教程亲测有效,一键激活。

Jetbrains全系列IDE稳定放心使用

Unable to process Jar entry [module-info.class] from Jar的问题解决

背景

在使用Eclipse进行Spring Boot应用开发时,如果项目启动是Run As->Run On Server方式运行就会报类似于Unable to process Jar entry [module-info.class] from Jar的错误,详细错误类似如下:

严重: Unable to process Jar entry [module-info.class] from Jar [file:/E:/workspace/.metadata/.plugins/org.eclipse.wst.server.core/tmp0/wtpwebapps/chapter-03-2/WEB-INF/lib/jackson-core-2.10.1.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:97)
	at org.apache.tomcat.util.bcel.classfile.ConstantPool.<init>(ConstantPool.java:54)
	at org.apache.tomcat.util.bcel.classfile.ClassParser.readConstantPool(ClassParser.java:174)
	at org.apache.tomcat.util.bcel.classfile.ClassParser.parse(ClassParser.java:83)
	at org.apache.catalina.startup.ContextConfig.processAnnotationsStream(ContextConfig.java:2053)
	at org.apache.catalina.startup.ContextConfig.processAnnotationsJar(ContextConfig.java:2000)
	at org.apache.catalina.startup.ContextConfig.processAnnotationsUrl(ContextConfig.java:1970)
	at org.apache.catalina.startup.ContextConfig.processAnnotations(ContextConfig.java:1923)
	at org.apache.catalina.startup.ContextConfig.webConfig(ContextConfig.java:1163)
	at org.apache.catalina.startup.ContextConfig.configureStart(ContextConfig.java:775)
	at org.apache.catalina.startup.ContextConfig.lifecycleEvent(ContextConfig.java:299)
	at org.apache.catalina.util.LifecycleBase.fireLifecycleEvent(LifecycleBase.java:94)
	at org.apache.catalina.core.StandardContext.startInternal(StandardContext.java:5087)
	at org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:150)
	at org.apache.catalina.core.ContainerBase$StartChild.call(ContainerBase.java:1419)
	at org.apache.catalina.core.ContainerBase$StartChild.call(ContainerBase.java:1409)
	at java.util.concurrent.FutureTask.run(FutureTask.java:266)
	at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1149)
	at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:624)
	at java.lang.Thread.run(Thread.java:748)

二月 27, 2020 9:34:31 上午 org.apache.catalina.startup.ContextConfig processAnnotationsJar
严重: Unable to process Jar entry [module-info.class] from Jar [file:/E:/workspace/.metadata/.plugins/org.eclipse.wst.server.core/tmp0/wtpwebapps/chapter-03-2/WEB-INF/lib/jackson-datatype-jsr310-2.10.1.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:97)
	at org.apache.tomcat.util.bcel.classfile.ConstantPool.<init>(ConstantPool.java:54)
	at org.apache.tomcat.util.bcel.classfile.ClassParser.readConstantPool(ClassParser.java:174)
	at org.apache.tomcat.util.bcel.classfile.ClassParser.parse(ClassParser.java:83)
	at org.apache.catalina.startup.ContextConfig.processAnnotationsStream(ContextConfig.java:2053)
	at org.apache.catalina.startup.ContextConfig.processAnnotationsJar(ContextConfig.java:2000)
	at org.apache.catalina.startup.ContextConfig.processAnnotationsUrl(ContextConfig.java:1970)
	at org.apache.catalina.startup.ContextConfig.processAnnotations(ContextConfig.java:1923)
	at org.apache.catalina.startup.ContextConfig.webConfig(ContextConfig.java:1163)
	at org.apache.catalina.startup.ContextConfig.configureStart(ContextConfig.java:775)
	at org.apache.catalina.startup.ContextConfig.lifecycleEvent(ContextConfig.java:299)
	at org.apache.catalina.util.LifecycleBase.fireLifecycleEvent(LifecycleBase.java:94)
	at org.apache.catalina.core.StandardContext.startInternal(StandardContext.java:5087)
	at org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:150)
	at org.apache.catalina.core.ContainerBase$StartChild.call(ContainerBase.java:1419)
	at org.apache.catalina.core.ContainerBase$StartChild.call(ContainerBase.java:1409)
	at java.util.concurrent.FutureTask.run(FutureTask.java:266)
	at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1149)
	at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:624)
	at java.lang.Thread.run(Thread.java:748)

二月 27, 2020 9:34:32 上午 org.apache.catalina.startup.ContextConfig processAnnotationsJar
严重: Unable to process Jar entry [module-info.class] from Jar [file:/E:/workspace/.metadata/.plugins/org.eclipse.wst.server.core/tmp0/wtpwebapps/chapter-03-2/WEB-INF/lib/jackson-module-parameter-names-2.10.1.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:97)
	at org.apache.tomcat.util.bcel.classfile.ConstantPool.<init>(ConstantPool.java:54)
	at org.apache.tomcat.util.bcel.classfile.ClassParser.readConstantPool(ClassParser.java:174)
	at org.apache.tomcat.util.bcel.classfile.ClassParser.parse(ClassParser.java:83)
	at org.apache.catalina.startup.ContextConfig.processAnnotationsStream(ContextConfig.java:2053)
	at org.apache.catalina.startup.ContextConfig.processAnnotationsJar(ContextConfig.java:2000)
	at org.apache.catalina.startup.ContextConfig.processAnnotationsUrl(ContextConfig.java:1970)
	at org.apache.catalina.startup.ContextConfig.processAnnotations(ContextConfig.java:1923)
	at org.apache.catalina.startup.ContextConfig.webConfig(ContextConfig.java:1163)
	at org.apache.catalina.startup.ContextConfig.configureStart(ContextConfig.java:775)
	at org.apache.catalina.startup.ContextConfig.lifecycleEvent(ContextConfig.java:299)
	at org.apache.catalina.util.LifecycleBase.fireLifecycleEvent(LifecycleBase.java:94)
	at org.apache.catalina.core.StandardContext.startInternal(StandardContext.java:5087)
	at org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:150)
	at org.apache.catalina.core.ContainerBase$StartChild.call(ContainerBase.java:1419)
	at org.apache.catalina.core.ContainerBase$StartChild.call(ContainerBase.java:1409)
	at java.util.concurrent.FutureTask.run(FutureTask.java:266)
	at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1149)
	at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:624)
	at java.lang.Thread.run(Thread.java:748)

二月 27, 2020 9:34:32 上午 org.apache.catalina.startup.ContextConfig processAnnotationsJar
严重: Unable to process Jar entry [module-info.class] from Jar [file:/E:/workspace/.metadata/.plugins/org.eclipse.wst.server.core/tmp0/wtpwebapps/chapter-03-2/WEB-INF/lib/jackson-annotations-2.10.1.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:97)
	at org.apache.tomcat.util.bcel.classfile.ConstantPool.<init>(ConstantPool.java:54)
	at org.apache.tomcat.util.bcel.classfile.ClassParser.readConstantPool(ClassParser.java:174)
	at org.apache.tomcat.util.bcel.classfile.ClassParser.parse(ClassParser.java:83)
	at org.apache.catalina.startup.ContextConfig.processAnnotationsStream(ContextConfig.java:2053)
	at org.apache.catalina.startup.ContextConfig.processAnnotationsJar(ContextConfig.java:2000)
	at org.apache.catalina.startup.ContextConfig.processAnnotationsUrl(ContextConfig.java:1970)
	at org.apache.catalina.startup.ContextConfig.processAnnotations(ContextConfig.java:1923)
	at org.apache.catalina.startup.ContextConfig.webConfig(ContextConfig.java:1163)
	at org.apache.catalina.startup.ContextConfig.configureStart(ContextConfig.java:775)
	at org.apache.catalina.startup.ContextConfig.lifecycleEvent(ContextConfig.java:299)
	at org.apache.catalina.util.LifecycleBase.fireLifecycleEvent(LifecycleBase.java:94)
	at org.apache.catalina.core.StandardContext.startInternal(StandardContext.java:5087)
	at org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:150)
	at org.apache.catalina.core.ContainerBase$StartChild.call(ContainerBase.java:1419)
	at org.apache.catalina.core.ContainerBase$StartChild.call(ContainerBase.java:1409)
	at java.util.concurrent.FutureTask.run(FutureTask.java:266)
	at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1149)
	at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:624)
	at java.lang.Thread.run(Thread.java:748)

二月 27, 2020 9:34:32 上午 org.apache.catalina.startup.ContextConfig processAnnotationsJar
严重: Unable to process Jar entry [module-info.class] from Jar [file:/E:/workspace/.metadata/.plugins/org.eclipse.wst.server.core/tmp0/wtpwebapps/chapter-03-2/WEB-INF/lib/jackson-databind-2.10.1.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:97)
	at org.apache.tomcat.util.bcel.classfile.ConstantPool.<init>(ConstantPool.java:54)
	at org.apache.tomcat.util.bcel.classfile.ClassParser.readConstantPool(ClassParser.java:174)
	at org.apache.tomcat.util.bcel.classfile.ClassParser.parse(ClassParser.java:83)
	at org.apache.catalina.startup.ContextConfig.processAnnotationsStream(ContextConfig.java:2053)
	at org.apache.catalina.startup.ContextConfig.processAnnotationsJar(ContextConfig.java:2000)
	at org.apache.catalina.startup.ContextConfig.processAnnotationsUrl(ContextConfig.java:1970)
	at org.apache.catalina.startup.ContextConfig.processAnnotations(ContextConfig.java:1923)
	at org.apache.catalina.startup.ContextConfig.webConfig(ContextConfig.java:1163)
	at org.apache.catalina.startup.ContextConfig.configureStart(ContextConfig.java:775)
	at org.apache.catalina.startup.ContextConfig.lifecycleEvent(ContextConfig.java:299)
	at org.apache.catalina.util.LifecycleBase.fireLifecycleEvent(LifecycleBase.java:94)
	at org.apache.catalina.core.StandardContext.startInternal(StandardContext.java:5087)
	at org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:150)
	at org.apache.catalina.core.ContainerBase$StartChild.call(ContainerBase.java:1419)
	at org.apache.catalina.core.ContainerBase$StartChild.call(ContainerBase.java:1409)
	at java.util.concurrent.FutureTask.run(FutureTask.java:266)
	at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1149)
	at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:624)
	at java.lang.Thread.run(Thread.java:748)

二月 27, 2020 9:34:33 上午 org.apache.catalina.startup.ContextConfig processAnnotationsJar
严重: Unable to process Jar entry [module-info.class] from Jar [file:/E:/workspace/.metadata/.plugins/org.eclipse.wst.server.core/tmp0/wtpwebapps/chapter-03-2/WEB-INF/lib/jackson-datatype-jdk8-2.10.1.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:97)
	at org.apache.tomcat.util.bcel.classfile.ConstantPool.<init>(ConstantPool.java:54)
	at org.apache.tomcat.util.bcel.classfile.ClassParser.readConstantPool(ClassParser.java:174)
	at org.apache.tomcat.util.bcel.classfile.ClassParser.parse(ClassParser.java:83)
	at org.apache.catalina.startup.ContextConfig.processAnnotationsStream(ContextConfig.java:2053)
	at org.apache.catalina.startup.ContextConfig.processAnnotationsJar(ContextConfig.java:2000)
	at org.apache.catalina.startup.ContextConfig.processAnnotationsUrl(ContextConfig.java:1970)
	at org.apache.catalina.startup.ContextConfig.processAnnotations(ContextConfig.java:1923)
	at org.apache.catalina.startup.ContextConfig.webConfig(ContextConfig.java:1163)
	at org.apache.catalina.startup.ContextConfig.configureStart(ContextConfig.java:775)
	at org.apache.catalina.startup.ContextConfig.lifecycleEvent(ContextConfig.java:299)
	at org.apache.catalina.util.LifecycleBase.fireLifecycleEvent(LifecycleBase.java:94)
	at org.apache.catalina.core.StandardContext.startInternal(StandardContext.java:5087)
	at org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:150)
	at org.apache.catalina.core.ContainerBase$StartChild.call(ContainerBase.java:1419)
	at org.apache.catalina.core.ContainerBase$StartChild.call(ContainerBase.java:1409)
	at java.util.concurrent.FutureTask.run(FutureTask.java:266)
	at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1149)
	at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:624)
	at java.lang.Thread.run(Thread.java:748)

二月 27, 2020 9:34:37 上午 org.apache.jasper.servlet.TldScanner scanJars
信息: At least one JAR was scanned for TLDs yet contained no TLDs. Enable debug logging for this logger for a complete list of JARs that were scanned but no TLDs were found in them. Skipping unneeded JARs during scanning can improve startup time and JSP compilation time.
二月 27, 2020 9:34:37 上午 org.apache.catalina.core.ApplicationContext log
信息: 2 Spring WebApplicationInitializers detected on classpath

Unable to process Jar entry [module-info.class] from Jar[file:/E:/workspace/.metadata/.plugins/org.eclipse.wst.server.core/tmp0/wtpwebapps/信息后面可能跟的jar文件不同。

解决办法

出现这种问题,是因为我们启动工程的方式不对造成的,Spring Boot应用要在工程右键菜单中选择Run As->Spring Boot App的方式启动,启动后的日志如下:


  .   ____          _            __ _ _
 /\\ / ___'_ __ _ _(_)_ __  __ _ \ \ \ \
( ( )\___ | '_ | '_| | '_ \/ _` | \ \ \ \
 \\/  ___)| |_)| | | | | || (_| |  ) ) ) )
  '  |____| .__|_| |_|_| |_\__, | / / / /
 =========|_|==============|___/=/_/_/_/
 :: Spring Boot ::             (v2.3.0.M2)

2020-02-27 09:43:51.984  INFO 17252 --- [           main] com.cloud.skyme.Chapter032Application    : Starting Chapter032Application on Sc-201506092204 with PID 17252 (E:\workspace\chapter-03-2\target\classes started by Administrator in E:\workspace\chapter-03-2)
2020-02-27 09:43:51.987  INFO 17252 --- [           main] com.cloud.skyme.Chapter032Application    : No active profile set, falling back to default profiles: default
2020-02-27 09:43:52.615  INFO 17252 --- [           main] o.s.b.w.embedded.tomcat.TomcatWebServer  : Tomcat initialized with port(s): 8080 (http)
2020-02-27 09:43:52.622  INFO 17252 --- [           main] o.apache.catalina.core.StandardService   : Starting service [Tomcat]
2020-02-27 09:43:52.622  INFO 17252 --- [           main] org.apache.catalina.core.StandardEngine  : Starting Servlet engine: [Apache Tomcat/9.0.31]
2020-02-27 09:43:52.702  INFO 17252 --- [           main] o.a.c.c.C.[Tomcat].[localhost].[/]       : Initializing Spring embedded WebApplicationContext
2020-02-27 09:43:52.702  INFO 17252 --- [           main] o.s.web.context.ContextLoader            : Root WebApplicationContext: initialization completed in 685 ms
2020-02-27 09:43:52.808  INFO 17252 --- [           main] o.s.s.concurrent.ThreadPoolTaskExecutor  : Initializing ExecutorService 'applicationTaskExecutor'
2020-02-27 09:43:52.908  INFO 17252 --- [           main] o.s.b.w.embedded.tomcat.TomcatWebServer  : Tomcat started on port(s): 8080 (http) with context path ''
2020-02-27 09:43:52.912  INFO 17252 --- [           main] com.cloud.skyme.Chapter032Application    : Started Chapter032Application in 1.149 seconds (JVM running for 1.818)

这样基本就正常了。

版权声明:本文内容由互联网用户自发贡献,该文观点仅代表作者本人。本站仅提供信息存储空间服务,不拥有所有权,不承担相关法律责任。如发现本站有涉嫌侵权/违法违规的内容, 请发送邮件至 举报,一经查实,本站将立刻删除。

发布者:全栈程序员-用户IM,转载请注明出处:https://javaforall.cn/188110.html原文链接:https://javaforall.cn

【正版授权,激活自己账号】: Jetbrains全家桶Ide使用,1年售后保障,每天仅需1毛

【官方授权 正版激活】: 官方授权 正版激活 支持Jetbrains家族下所有IDE 使用个人JB账号...

(0)


相关推荐

  • 初步了解印度数学速算法

    初步了解印度数学速算法印度也是IT发达的国家;初步了解,印度的数学自己有一套东西,有的和我们从小学的有很大区别;它的速算法,有的计算看一眼就能给出答案;这东西练一下也许能帮助减低脑力劳动强度;大家有兴趣自己研究;先初步了解一下;下图,一看就给出答案;它的算法是,14加3得17,扩大10倍170,再加上3*4的结果12,最后结果182;对于十位上的数字相同,两位数乘两位数的算法:如:15*16(1)15+6=21(2)21*10=210(3)5*6=30(4)210+30=240…

  • Nginx加密以及反向代理「建议收藏」

    Nginx加密以及反向代理「建议收藏」一、https加密算法http协议在传输过程中使用的是明文,如果传输的是用户名和密码等信息就不安全。https就是在原来http协议中加上ssl算法,来对传输的数据进行加密。https加密的核心就是通过秘钥来实现。秘钥(加密算法)的分类:1.对称算法(加密和解密用一样的密码):AES,DES(适合单机加密)2.非对称算法(公钥和私钥):RSA,DSA3.信息摘要:md5,sha256…

  • Objective-C —点语法 (梳理整理)

    Objective-C —点语法 (梳理整理)

  • 迭代和递归的理解和区别

    迭代和递归的理解和区别最近做一些题经常会碰到迭代的方法解的,或者递归解法,容易搞混,特在此整理一下一.递归:由例子引出,先看看递归的经典案例都有哪些1.斐波那契数列斐波纳契数列,又称黄金分割数列,指的是这样一个数列:1、1、2、3、5、8、13、21、……这个数列从第三项开始,每一项都等于前两项之和。2.阶乘n!=n*(n-1)*(n-2)*…*1(n>0)3.汉诺塔问…

  • 双管道(CreatePipe)与本地cmd.exe进程通信(附源代码及编译好的程序,免费下载)

    双管道(CreatePipe)与本地cmd.exe进程通信(附源代码及编译好的程序,免费下载)源代码:#include<stdio.h>#include<WINDOWS.H>#defineSEND_BUFF_SIZE1024//实现去除执行结果中的”命令\n”voidprint(char*cmdstr){ while(*((char*)cmdstr++)!=’\n’); printf(cmdstr);}intmai…

  • iOS的高德地图标注特定位置

    iOS的高德地图标注特定位置在开发时有时候遇到项目里面需要展示公司的位置,这时如果导入百度地图什么的就太浪费资源,而且还占内存这时只要调用自动高德地图的就行了自己写一个控制器,导入框架现在导入系统框架只要多打次就能出来了,没必要去link添加1#import”MapViewCtl.h”2#import<CoreLocation/CoreLocation.h>3#impo…

发表回复

您的电子邮箱地址不会被公开。

关注全栈程序员社区公众号