dubbo和spring的BeanFactory有冲突吗???

在尝试整合SpringMvc+maven+dubbo的项目时,启动消费端遇到BeanFactory未初始化或已关闭的错误,导致项目启动失败。问题出现在web.xml和spring-mvc.xml的配置中,怀疑可能存在dubbo与Spring的BeanFactory冲突。目前尚未使用dubbo注解,且在不包含dubbo的其他项目中未出现此类问题,寻求解决方案。
摘要由CSDN通过智能技术生成

BeanFactory not initialized or already closed - call 'refresh' before accessing beans via the ApplicationContext

这几天在接触dubbo,建了一个SpringMvc+maven+dubbo的工程。在测试启动消费端的项目是一直报错!
BeanFactory not initialized or already closed - call ‘refresh’ before accessing beans via the ApplicationContext

三月 14, 2019 11:23:55 上午 org.apache.catalina.core.StandardContext startInternal
严重: One or more listeners failed to start. Full details will be found in the appropriate container log file
三月 14, 2019 11:23:55 上午 org.apache.catalina.core.StandardContext startInternal
严重: Context [/dubbo-et1811-web-mvc] startup failed due to previous errors
三月 14, 2019 11:23:55 上午 org.apache.catalina.core.ApplicationContext log
信息: Closing Spring root WebApplicationContext
三月 14, 2019 11:23:55 上午 org.apache.catalina.core.StandardContext listenerStop
严重: 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

web.xml配置

<!DOCTYPE web-app PUBLIC
 "-//Sun Microsystems, Inc.//DTD Web Application 2.3//EN"
 "http://java.sun.com/dtd/web-app_2_3.dtd" >

<web-app>
  <filter>
  	<filter-name>encoding</filter-name>
  	<filter-class>org.springframework.web.filter.CharacterEncodingFilter</filter-class>
  	<init-param>
  		<param-name>encoding</param-name>
  		<param-value>UTF-8
  • 0
    点赞
  • 0
    收藏
    觉得还不错? 一键收藏
  • 0
    评论

“相关推荐”对你有帮助么?

  • 非常没帮助
  • 没帮助
  • 一般
  • 有帮助
  • 非常有帮助
提交
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

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

抵扣说明:

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

余额充值