Tomcat 迁移 至 weblogic部署war包,log4j问题 完整版

将Tomcat应用迁移到Weblogic时遇到log4j配置冲突问题,表现为WAR包直接部署报错,原因是Weblogic本身支持log4j与Spring的Log4jConfigListener冲突。解决办法包括:注释掉web.xml中的log4j相关配置,并创建weblogic.xml文件,设置特定参数来避免冲突。
摘要由CSDN通过智能技术生成
一、异常场景:
    发布war包到tomcat,jetty中正常部署,war包解压后用weblogic部署正常,war包直接在weblogic上部署异常:
Cannot set web app root system property when WAR file is not expanded


激活更改期间出错, 有关详细信息, 请查看日志。


消息图标 - 错误 java.lang.IllegalArgumentException: Invalid 'log4jConfigLocation' parameter: 
class path resource [log4j.properties] cannot be resolved to absolute file path
 because it does not reside in the file system:zip:
/home/oracle/domain/servers/AdminServer/tmp/_WL_user/teenagers-report/9dj5sc/war/WEB-INF/lib/_wl_cls_gen.jar!/log4j.properties
消息图标 - 错误 Invalid 'log4jConfigLocation' parameter: class path resource [log4j.properties] 
cannot be resolved to absolute file path because it does not reside in the file system: 
zip:/home/oracle/domain/servers/AdminServer/tmp/_WL_user/teenagers-report/9dj5sc/war/WEB-INF/lib/_wl_cls_gen.jar!/log4j.properties
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值