日期:2014-05-20  浏览次数:21188 次

nested exception is org.springframework.beans.TypeMismatchException: Failed to c
由于jar 包冲突项目经常起不来,刚刚重新配置了jar包出现 异常。一上午了都没有解决。
哪位高手帮帮忙,在线等啊。

nested exception is org.springframework.beans.TypeMismatchException: Failed to convert property value of type [java.lang.String] to required type [org.springframework.core.io.Resource[]] for property 'mappingLocations'; nested exception is java.lang.IllegalArgumentException: Could not resolve resource location pattern [classpath:hbms/*.hbm.xml]: class path resource [hbms/] cannot be resolved to URL because it does not exist

Java code

0 [main] INFO org.mortbay.log - Logging to org.slf4j.impl.SimpleLogger@9ed927 via org.mortbay.log.Slf4jLog
328 [main] INFO org.mortbay.log - jetty 6.0.0rc0
609 [main] INFO / - Initializing Spring root WebApplicationContext
609 [main] INFO org.springframework.web.context.ContextLoader - Root WebApplicationContext: initialization started
656 [main] INFO org.springframework.web.context.support.XmlWebApplicationContext - Refreshing org.springframework.web.context.support.XmlWebApplicationContext@120bf2c: display name [Root WebApplicationContext]; startup date [Mon Dec 28 11:15:35 CST 2009]; root of context hierarchy
750 [main] INFO org.springframework.beans.factory.xml.XmlBeanDefinitionReader - Loading XML bean definitions from ServletContext resource [/WEB-INF/applicationContext.xml]
968 [main] INFO org.springframework.web.context.support.XmlWebApplicationContext - Bean factory for application context [org.springframework.web.context.support.XmlWebApplicationContext@120bf2c]: org.springframework.beans.factory.support.DefaultListableBeanFactory@491c4c
1250 [main] INFO org.springframework.beans.factory.config.PropertyPlaceholderConfigurer - Loading properties file from ServletContext resource [/WEB-INF/data-access.properties]
1312 [main] INFO org.springframework.beans.factory.support.DefaultListableBeanFactory - Pre-instantiating singletons in org.springframework.beans.factory.support.DefaultListableBeanFactory@491c4c: defining beans [emailEnterParameter,emailSender,propertyConfigurer,transactionManager,sessionFactory,dataSource,productDao,productCategoryDao,productClassDao,productBenefitDao,productUsageDao,productSalesDao,productCustomerCaseDao,newsDao,infoIndexDao,dataDao,introduceDao,faqDao,branchDao,comDataDao,jobDao,careerDao,messageBoardDao,sysusertbDao,syspurviewtbDao,asiaTourAwardDao,webStaticDao,environDao,almsdeedDao,managementTeamDao,bicycleDao,nutritionDao,sponsorshipDao,nutritionArticleDao,promotionDao,awardsDao,downloadDao,sqlDao,productManager,productCategoryManager,productClassManager,productBenefitManager,productUsageManager,productSalesManager,productCustomerCaseManager,newsManager,introduceManager,faqManager,branchManager,dataManager,infoIndexManager,comDataManager,jobManager,careerManager,messageBoardManager,sysusertbManager,syspurviewtbManager,asiaTourAwardManager,webStaticManager,environManager,almsdeedManager,managementTeamManager,bicycleManager,nutritionManager,sponsorshipManager,nutritionArticleManager,promotionManager,awardsManager,downloadManager,facade]; root of factory hierarchy
1937 [main] INFO org.springframework.beans.factory.support.DefaultListableBeanFactory - Destroying singletons in org.springframework.beans.factory.support.DefaultListableBeanFactory@491c4c: defining beans [emailEnterParameter,emailSender,propertyConfigurer,transactionManager,sessionFactory,dataSource,productDao,productCategoryDao,productClassDao,productBenefitDao,productUsageDao,productSalesDao,productCustomerCaseDao,newsDao,infoIndexDao,dataDao,introduceDao,faqDao,branchDao,comDataDao,jobDao,careerDao,messageBoardDao,sysusertbDao,syspurviewtbDao,asiaTourAwardDao,webStaticDao,environDao,almsdeedDao,managementTeamDao,bicycleDao,nutritionDao,sponsorshipDao,nutritionArticleDao,promotionDao,awardsDao,downloadDao,sqlDao,productManager,productCategoryManager,productClassManager,productBenefitManager,productUsageManager,productSalesManager,productCustomerCaseManager,newsManager,introduceManager,faqManager,branchManager,dataManager,infoIndexManager,comDataManager,jobManager,careerManager,messageBoardManager,sysusertbManager,syspurviewtbManager,asiaTourAwardManager,webStaticManager,environManager,almsdeedManager,managementTeamManager,bicycleManager,nutritionManager,sponsorshipManager,nutritionArticleManager,promotionManager,awardsManager,downloadManager,facade]; root of factory hierarchy
1937 [main] ERROR org.springframework.web.context.ContextLoader - Context initialization failed
org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'transactionManager' defined in ServletContext resource [/WEB-INF/applicationContext.xml]: Cannot resolve reference to bean 'sessionFactory' while setting bean property 'sessionFactory'; nested exception is org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'sessionFactory' defined in ServletContext resource [/WEB-INF/applicationContext.xml]: Initialization of bean failed; nested exception is org.springframework.beans.TypeMismatchException: Failed to convert property value of type [java.lang.String] to required type [org.springframework.core.io.Resource[]] for property 'mappingLocations'; nested exception is java.lang.IllegalArgumentException: Could not resolve resource location pattern [classpath:hbms/*.hbm.xml]: class path resource [hbms/] cannot be resolved to URL because it does not exist
Caused by: org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'sessionFactory' defined in ServletContext resource [/WEB-INF/applicationContext.xml]: Initialization of bean failed; nested exception is org.springframework.beans.TypeMismatchException: Failed to convert property value of type [java.lang.String] to required type [org.springframework.core.io.Resource[]] for property 'mappingLocations'; nested exception is java.lang.IllegalArgumentException: Could not resolve resource location pattern [classpath:hbms/*.hbm.xml]: class path resource [hbms/] cannot be resolved to URL because it does not exist
Caused by: org.springframework.beans.TypeMismatchException: Failed to convert property value of type [java.lang.String] to required type [org.springframework.core.io.Resource[]] for property 'mappingLocations'; nested exception is java.lang.IllegalArgumentException: Could not resolve resource location pattern [classpath:hbms/*.hbm.xml]: class path resource [hbms/] cannot be resolved to URL because it does not exist
Caused by: java.lang.IllegalArgumentException: Could not resolve resource location pattern [classpath:hbms/*.hbm.xml]: class path resource [hbms/] cannot be resolved to URL because it does not exist
    at org.springframework.core.io.support.ResourceArrayPropertyEditor.setAsText(ResourceArrayPropertyEditor.java:83)
    at org.springframework.beans.TypeConverterDelegate.doConvertTextValue(TypeConverterDelegate.java:320)
    at org.springframework.beans.TypeConverterDelegate.doConvertValue(TypeConverterDelegate.java:304)
    at org.springframework.beans.TypeConverterDelegate.convertIfNecessary(TypeConverterDelegate.java:192)
    at org.springframework.beans.TypeConverterDelegate.convertIfNecessary(TypeConverterDelegate.java:138)
    at org.springframework.beans.BeanWrapperImpl.convertForProperty(BeanWrapperImpl.java:380)
    at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.applyPropertyValues(AbstractAutowireCapableBeanFactory.java:1085)
    at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.populateBean(AbstractAutowireCapableBeanFactory.java:835)
    at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.createBean(AbstractAutowireCapableBeanFactory.java:423)
    at org.springframework.beans.factory.support.AbstractBeanFactory$1.getObject(AbstractBeanFactory.java:251)
    at org.springframework.beans.factory.support.DefaultSingletonBeanRegistry.getSingleton(DefaultSingletonBeanRegistry.java:144)
    at org.springframework.beans.factory.support.AbstractBeanFactory.getBean(AbstractBeanFactory.java:248)
    at org.springframework.beans.factory.support.AbstractBeanFactory.getBean(AbstractBeanFactory.java:160)
    at org.springframework.beans.factory.support.BeanDefinitionValueResolver.resolveReference(BeanDefinitionValueResolver.java:261)
    at org.springframework.beans.factory.support.BeanDefinitionValueResolver.resolveValueIfNecessary(BeanDefinitionValueResolver.java:109)
    at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.applyPropertyValues(AbstractAutowireCapableBeanFactory.java:1073)
    at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.populateBean(AbstractAutowireCapableBeanFactory.java:835)
    at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.createBean(AbstractAutowireCapableBeanFactory.java:423)
    at org.springframework.beans.factory.support.AbstractBeanFactory$1.getObject(AbstractBeanFactory.java:251)
    at org.springframework.beans.factory.support.DefaultSingletonBeanRegistry.getSingleton(DefaultSingletonBeanRegistry.java:144)
    at org.springframework.beans.factory.support.AbstractBeanFactory.getBean(AbstractBeanFactory.java:248)
    at org.springframework.beans.factory.support.AbstractBeanFactory.getBean(AbstractBeanFactory.java:160)
    at org.springframework.beans.factory.support.DefaultListableBeanFactory.preInstantiateSingletons(DefaultListableBeanFactory.java:279)
    at org.springframework.context.support.AbstractApplicationContext.refresh(AbstractApplicationContext.java:360)
    at org.springframework.web.context.ContextLoader.createWebApplicationContext(ContextLoader.java:241)
    at org.springframework.web.context.ContextLoader.initWebApplicationContext(ContextLoader.java:184)
    at org.springframework.web.context.ContextLoaderListener.contextInitialized(ContextLoaderListener.java:49)