Spring 4.1.6应用程序上下文初始化失败

时间:2015-05-22 11:21:54

标签: java spring

我正在尝试将我的旧版Spring Web应用程序从3.1升级到4.1.6.RELEASE。 我面临以下例外。

[localhost-startStop-1] ERROR
org.springframework.web.context.ContextLoader - Context initialization
failed java.lang.IllegalAccessError: tried to access method
org.springframework.beans.factory.support.DefaultSingletonBeanRegistry.getSingletonMutex()Ljava/lang/Object;
from class
org.springframework.context.event.AbstractApplicationEventMulticaster
    at
org.springframework.context.event.AbstractApplicationEventMulticaster.setBeanFactory(AbstractApplicationEventMulticaster.java:84)
    at
org.springframework.context.event.SimpleApplicationEventMulticaster.<init>(SimpleApplicationEventMulticaster.java:60)
    at
org.springframework.context.support.AbstractApplicationContext.initApplicationEventMulticaster(AbstractApplicationContext.java:667)
    at
org.springframework.context.support.AbstractApplicationContext.refresh(AbstractApplicationContext.java:471)
    at
org.springframework.web.context.ContextLoader.configureAndRefreshWebApplicationContext(ContextLoader.java:403)
    at
org.springframework.web.context.ContextLoader.initWebApplicationContext(ContextLoader.java:306)
    at
org.springframework.web.context.ContextLoaderListener.contextInitialized(ContextLoaderListener.java:106)
    at
org.apache.catalina.core.StandardContext.listenerStart(StandardContext.java:4797)
    at
org.apache.catalina.core.StandardContext.startInternal(StandardContext.java:5291)
    at
org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:150)
    at
org.apache.catalina.core.ContainerBase$StartChild.call(ContainerBase.java:1559)
    at
org.apache.catalina.core.ContainerBase$StartChild.call(ContainerBase.java:1549)
    at java.util.concurrent.FutureTask.run(FutureTask.java:266)     at
java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1142)
    at
java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:617)
    at java.lang.Thread.run(Thread.java:745) May 22, 2015 11:01:07 AM
org.apache.catalina.core.StandardContext listenerStart

1 个答案:

答案 0 :(得分:0)

我有同样的问题;在我的情况下,它是一个传递依赖于Spring 4.1.5.RELEASE引起的spring-batch-core 3.0.4.RELEASE。