首页 诗词 字典 板报 句子 名言 友答 励志 学校 网站地图
当前位置: 首页 > 教程频道 > JAVA > J2EE开发 >

weblogic起步web工程包java.lang.NoSuchMethodError

2012-09-03 
weblogic启动web工程包java.lang.NoSuchMethodErrorUser defined listener org.springframework.web.cont

weblogic启动web工程包java.lang.NoSuchMethodError
<User defined listener org.springframework.web.context.ContextLoaderListener failed: java.lang.NoSuchMethodError: org/springframework/beans/factory/support/DefaultListableBeanFactory.setSerializationId(Ljava/lang/String;)V.
java.lang.NoSuchMethodError: org/springframework/beans/factory/support/DefaultListableBeanFactory.setSerializationId(Ljava/lang/String;)V
at org.springframework.context.support.AbstractRefreshableApplicationContext.refreshBeanFactory(AbstractRefreshableApplicationContext.java:128)
at org.springframework.context.support.AbstractApplicationContext.obtainFreshBeanFactory(AbstractApplicationContext.java:465)
at org.springframework.context.support.AbstractApplicationContext.refresh(AbstractApplicationContext.java:395)
at org.springframework.web.context.support.AbstractRefreshableWebApplicationContext.refresh(AbstractRefreshableWebApplicationContext.java:156)
at org.springframework.web.context.ContextLoader.createWebApplicationContext(ContextLoader.java:246)
Truncated. see log file for complete stacktrace

<Aug 30, 2012 6:45:41 PM CST> <Error> <Deployer> <BEA-149231> <Unable to set the activation state to true for the application 'wap'.
weblogic.application.ModuleException: 
at weblogic.servlet.internal.WebAppModule.startContexts(WebAppModule.java:1514)
at weblogic.servlet.internal.WebAppModule.start(WebAppModule.java:486)
at weblogic.application.internal.flow.ModuleStateDriver$3.next(ModuleStateDriver.java:425)
at weblogic.application.utils.StateMachineDriver.nextState(StateMachineDriver.java:41)
at weblogic.application.internal.flow.ModuleStateDriver.start(ModuleStateDriver.java:119)
Truncated. see log file for complete stacktrace

Caused By: java.lang.NoSuchMethodError: org/springframework/beans/factory/support/DefaultListableBeanFactory.setSerializationId(Ljava/lang/String;)V
at org.springframework.context.support.AbstractRefreshableApplicationContext.refreshBeanFactory(AbstractRefreshableApplicationContext.java:128)
at org.springframework.context.support.AbstractApplicationContext.obtainFreshBeanFactory(AbstractApplicationContext.java:465)
at org.springframework.context.support.AbstractApplicationContext.refresh(AbstractApplicationContext.java:395)
at org.springframework.web.context.support.AbstractRefreshableWebApplicationContext.refresh(AbstractRefreshableWebApplicationContext.java:156)
at org.springframework.web.context.ContextLoader.createWebApplicationContext(ContextLoader.java:246)
Truncated. see log file for complete stacktrace

<Aug 30, 2012 6:45:41 PM CST> <Notice> <Log Management> <BEA-170027> <The Server has established connection with the Domain level Diagnostic Service successfully.> 
<Aug 30, 2012 6:45:42 PM CST> <Notice> <WebLogicServer> <BEA-000365> <Server state changed to ADMIN> 
<Aug 30, 2012 6:45:42 PM CST> <Notice> <WebLogicServer> <BEA-000365> <Server state changed to RESUMING> 
<Aug 30, 2012 6:45:42 PM CST> <Notice> <Server> <BEA-002613> <Channel "Default[1]" is now listening on fe80:0:0:0:218:8bff:fee5:8a13:6001 for protocols iiop, t3, ldap, snmp, http.> 
<Aug 30, 2012 6:45:42 PM CST> <Notice> <Server> <BEA-002613> <Channel "Default[2]" is now listening on 127.0.0.1:6001 for protocols iiop, t3, ldap, snmp, http.> 
<Aug 30, 2012 6:45:42 PM CST> <Notice> <Server> <BEA-002613> <Channel "Default[3]" is now listening on 0:0:0:0:0:0:0:1:6001 for protocols iiop, t3, ldap, snmp, http.> 
<Aug 30, 2012 6:45:42 PM CST> <Notice> <Server> <BEA-002613> <Channel "Default" is now listening on 172.100.2.166:6001 for protocols iiop, t3, ldap, snmp, http.> 


<Aug 30, 2012 6:45:42 PM CST> <Notice> <WebLogicServer> <BEA-000329> <Started WebLogic Admin Server "AdminServer" for domain "wapDomain" running in Production Mode> 
<Aug 30, 2012 6:45:42 PM CST> <Notice> <WebLogicServer> <BEA-000365> <Server state changed to RUNNING> 
<Aug 30, 2012 6:45:42 PM CST> <Notice> <WebLogicServer> <BEA-000360> <Server started in RUNNING mode> 
其中有DefaultListableBeanFactory房的Jar有spring.jar和org.springframework.asm-3.0.2.RELEASE这2个jar包,本地tomact启动OK,但是放到服务器上weblogic启动就报错!
求大神指点呀!

[解决办法]
java.lang.NoSuchMethodError: org/springframework/beans/factory/support/DefaultListableBeanFactory.setSerializationId

这种错误一般 95% 以上概率,说明你用了不匹配的jar包。

再结合你所说的 tomcat 启动OK,Weblogic启动报错。

那可能还得检查下是否跟Weblogic存在冲突,或者说你是否在Weblogic的CLASSPATH或 JDK 的 ext 之类的地方,装载了冲突的jar包。
[解决办法]
看看这个

在weblogic.xml中配置,如下: 
<container-descriptor> 
<prefer-web-inf-classes>true</prefer-web-inf-classes> 
</container-descriptor> 

文章在这里
http://shuwen.iteye.com/blog/1124220
[解决办法]

探讨
再补充下,在测试weblogic下跑都是OK的,打到生产环境的weblogic下就挂了!这个需要检查2个环境那些地方呢?JDK和weblogic版本都一样的!

热点排行