2 yeyu pds yeyu_pds 于 2017.09.10 17:06 提问

myeclipse的ssh框架配置出错了 10C

严重: Exception sending context destroyed event to listener instance of class org.springframework.web.context.ContextLoaderListener
java.lang.IllegalStateException: BeanFactory not initialized or already closed - call 'refresh' before accessing beans via the ApplicationContext
at org.springframework.context.support.AbstractRefreshableApplicationContext.getBeanFactory(AbstractRefreshableApplicationContext.java:170)
at org.springframework.context.support.AbstractApplicationContext.destroyBeans(AbstractApplicationContext.java:1006)
at org.springframework.context.support.AbstractApplicationContext.doClose(AbstractApplicationContext.java:982)
at org.springframework.context.support.AbstractApplicationContext.close(AbstractApplicationContext.java:934)
at org.springframework.web.context.ContextLoader.closeWebApplicationContext(ContextLoader.java:583)
at org.springframework.web.context.ContextLoaderListener.contextDestroyed(ContextLoaderListener.java:116)
at org.apache.catalina.core.StandardContext.listenerStop(StandardContext.java:4900)
at org.apache.catalina.core.StandardContext.stopInternal(StandardContext.java:5537)
at org.apache.catalina.util.LifecycleBase.stop(LifecycleBase.java:221)
at org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:149)
at org.apache.catalina.core.ContainerBase.addChildInternal(ContainerBase.java:753)
at org.apache.catalina.core.ContainerBase.addChild(ContainerBase.java:729)
at org.apache.catalina.core.StandardHost.addChild(StandardHost.java:717)
at org.apache.catalina.startup.HostConfig.deployDirectory(HostConfig.java:1129)
at org.apache.catalina.startup.HostConfig$DeployDirectory.run(HostConfig.java:1871)
at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:511)
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)

8个回答

dongfeng9ge
dongfeng9ge   Ds   Rxr 2017.09.10 18:39

不要用SSH了,试试SpringMVC吧

wb_coder
wb_coder   2017.09.10 18:06

cleanup一下工程试下

sinat_30160727
sinat_30160727   2017.09.10 20:01

jar包有没有导入,其次再看web.xml的配置,这个应该是启动服务器就报错了。

baidu_35975930
baidu_35975930   2017.09.10 21:40

是运行时报错吗??????

ShewMi
ShewMi   2017.09.10 22:46

添加
org.springframework.web.context.ContextLoaderListener

ShewMi
ShewMi   2017.09.10 22:46


org.springframework.web.context.ContextLoaderListener

ShewMi
ShewMi   2017.09.10 22:48

xml标签显示不出来,在WEB。xml配置

 <listener>
        <listener-class>org.springframework.web.context.ContextLoaderListener</listener-class>
    </listener>
u013934408
u013934408   2017.09.11 21:03

path环境变量里面是否引入spring的jar包;web.xml文件里面ContextLoaderListener监听器是否配置正确

Csdn user default icon
上传中...
上传图片
插入图片