当我在tomcat中部署shopizer.war时,我遇到了错误

时间:2016-04-12 15:32:06

标签: java spring maven tomcat shopizer

SEVERE: Exception sending context initialized event to listener instance 
    of   
    class org.springframework.web.context.ContextLoaderListener
    org.springframework.beans.factory.BeanCreationException: 
    Error creating bean with name 'categoryDao': Injection of
    persistence dependencies failed; nested exception 
    is org.springframework.beans.factory.CannotLoadBeanClassException:
    Error loading class [com.shopizer.modules.shipping.distance.
    ShippingDistancePreProcessorImpl] for 
    bean with name 'shippingDistancePreProcessor' defined 
    in class path resource 
    [spring/processors/shopizer-core-shipping-processors.xml]: 
    problem with class file or dependent class; nested exception 
    is java.lang.NoClassDefFoundError:  
    com/salesmanager/
    core/modules/integration/shipping/model/
    ShippingQuotePrePostProcessModule
    Related cause: 
    org.springframework.beans.factory.CannotLoadBeanClassException: 
    Error     loading class 

2 个答案:

答案 0 :(得分:0)

根据上面的堆栈跟踪很难回答,

但是我看到了一个java.lang.NoClassDefFoundError :,这表明你在运行时正在依赖一个依赖。我不确定您的项目是如何设置的,但请检查容器设置是否缺少依赖项。

答案 1 :(得分:0)

检查您是否已在spring-config.xml版本中定义了所有bean,如果您是Autowiring注释,请检查您的bean类是否已注释。