linux环境上报异常java.lang.NoSuchMethodError
23-Apr-2019 18:11:35.545 INFO [http-nio-10052-exec-10] org.apache.catalina.core.ApplicationContext.log No Spring WebApplicationInitializer types detected on classpath
23-Apr-2019 18:11:35.587 INFO [http-nio-10052-exec-10] org.apache.catalina.core.ApplicationContext.log [commontemplate] searched config: conf/commontemplate.properties
23-Apr-2019 18:11:35.595 INFO [http-nio-10052-exec-10] org.apache.catalina.core.ApplicationContext.log [commontemplate] Template engine initializing...
23-Apr-2019 18:11:35.953 INFO [http-nio-10052-exec-10] org.apache.catalina.core.ApplicationContext.log [commontemplate] Template engine initialized in 358 ms
23-Apr-2019 18:11:35.955 INFO [http-nio-10052-exec-10] org.apache.catalina.core.ApplicationContext.log Set web app root system property: 'xkzd.root' = [/opt/jdlserver_prd/app-school/xkzd/]
23-Apr-2019 18:11:35.958 INFO [http-nio-10052-exec-10] org.apache.catalina.core.ApplicationContext.log Initializing log4j from [/opt/jdlserver_prd/app-school/xkzd/WEB-INF/log4j.properties]
23-Apr-2019 18:11:35.980 SEVERE [http-nio-10052-exec-10] org.apache.catalina.core.StandardContext.listenerStart Exception sending context initialized event to listener instance of class conf.AppContextLoaderListener java.lang.NoSuchMethodError: org.apache.commons.io.IOUtils.toByteArray(Ljava/io/InputStream;J)[B at org.apache.commons.io.FileUtils.readFileToByteArray(FileUtils.java:1764) at conf.CheckAppStartCerticateValid.doCheck(Unknown Source) at conf.CheckAppStartCerticateValid.check(Unknown Source) at conf.AppContextLoaderListener.contextInitialized(Unknown Source) at org.apache.catalina.core.StandardContext.listenerStart(StandardContext.java:4729) at org.apache.catalina.core.StandardContext.startInternal(StandardContext.java:5167) at org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:150) at org.apache.catalina.manager.ManagerServlet.start(ManagerServlet.java:1293) at org.apache.catalina.manager.HTMLManagerServlet.start(HTMLManagerServlet.java:673) at org.apache.catalina.manager.HTMLManagerSer
以上报错是由于jar冲突的问题,检查一下报错的这个jar包是否还有与它同路径,同包名下的类,但是不在同一个jar里,需要检测下用到哪个jar,备份另一个删掉试试
【推荐】编程新体验,更懂你的AI,立即体验豆包MarsCode编程助手
【推荐】凌霞软件回馈社区,博客园 & 1Panel & Halo 联合会员上线
【推荐】抖音旗下AI助手豆包,你的智能百科全书,全免费不限次数
【推荐】轻量又高性能的 SSH 工具 IShell:AI 加持,快人一步
· 智能桌面机器人:用.NET IoT库控制舵机并多方法播放表情
· Linux glibc自带哈希表的用例及性能测试
· 深入理解 Mybatis 分库分表执行原理
· 如何打造一个高并发系统?
· .NET Core GC压缩(compact_phase)底层原理浅谈
· DeepSeek火爆全网,官网宕机?本地部署一个随便玩「LLM探索」
· 开发者新选择:用DeepSeek实现Cursor级智能编程的免费方案
· 【译】.NET 升级助手现在支持升级到集中式包管理
· 独立开发经验谈:如何通过 Docker 让潜在客户快速体验你的系统
· 并发编程 - 线程同步(二)