今天打开项目发现运行报错,昨天OK
报错如下;
2017-12-08 12:50:36,987 [Thread-2] DEBUG [org.springframework.beans.factory.support.DefaultListableBeanFactory] - Finished creating instance of bean 'securityManager'
2017-12-08 12:50:37,014 [Thread-2] DEBUG [org.springframework.beans.factory.support.DefaultListableBeanFactory] - Finished creating instance of bean 'shiroFilter'
2017-12-08 12:50:37,016 [Thread-2] DEBUG [org.springframework.web.context.support.XmlWebApplicationContext] - Unable to locate MessageSource with name 'messageSource': using default [org.springframework.context.support.DelegatingMessageSource@16a2795a]
2017-12-08 12:50:37,017 [Thread-2] DEBUG [org.springframework.web.context.support.XmlWebApplicationContext] - Unable to locate ApplicationEventMulticaster with name 'applicationEventMulticaster': using default [org.springframework.context.event.SimpleApplicationEventMulticaster@4cd0f52]
2017-12-08 12:50:37,018 [Thread-2] DEBUG [org.springframework.ui.context.support.UiApplicationContextUtils] - Unable to locate ThemeSource with name 'themeSource': using default [org.springframework.ui.context.support.ResourceBundleThemeSource@32a8d2f4]
2017-12-08 12:50:37,023 [Thread-2] DEBUG [org.springframework.beans.factory.support.DefaultListableBeanFactory] - Pre-instantiating singletons in org.springframework.beans.factory.support.DefaultListableBeanFactory@7e658391: defining beans [securityManager,cacheManager,jdbcRealm,lifecycleBeanPostProcessor,org.springframework.aop.framework.autoproxy.DefaultAdvisorAutoProxyCreator#0,org.apache.shiro.spring.security.interceptor.AuthorizationAttributeSourceAdvisor#0,shiroFilter,org.springframework.context.support.PropertySourcesPlaceholderConfigurer#0,dataSource,org.mybatis.spring.SqlSessionFactoryBean#0,clanMapper,org.mybatis.spring.mapper.MapperScannerConfigurer#0,busMapper,busorderMapper,busrecordMapper,busorderService,busrecordService,busService,emp1Mapper,permMapper,emp1Service,permService,bbsMapper,deptMapper,empMapper,roleMapper,org.springframework.context.annotation.internalConfigurationAnnotationProcessor,org.springframework.context.annotation.internalAutowiredAnnotationProcessor,org.springframework.context.annotation.internalRequiredAnnotationProcessor,org.springframework.context.annotation.internalCommonAnnotationProcessor,org.springframework.context.annotation.ConfigurationClassPostProcessor.importAwareProcessor,org.springframework.context.annotation.ConfigurationClassPostProcessor.enhancedConfigurationProcessor]; root of factory hierarchy
2017-12-08 12:50:37,023 [Thread-2] DEBUG [org.springframework.beans.factory.support.DefaultListableBeanFactory] - Returning cached instance of singleton bean 'securityManager'
2017-12-08 12:50:37,023 [Thread-2] DEBUG [org.springframework.beans.factory.support.DefaultListableBeanFactory] - Returning cached instance of singleton bean 'cacheManager'
2017-12-08 12:50:37,023 [Thread-2] DEBUG [org.springframework.beans.factory.support.DefaultListableBeanFactory] - Returning cached instance of singleton bean 'jdbcRealm'
2017-12-08 12:50:37,023 [Thread-2] DEBUG [org.springframework.beans.factory.support.DefaultListableBeanFactory] - Returning cached instance of singleton bean 'lifecycleBeanPostProcessor'
2017-12-08 12:50:37,038 [Thread-2] DEBUG [org.springframework.beans.factory.support.DefaultListableBeanFactory] - Returning cached instance of singleton bean 'org.springframework.aop.framework.autoproxy.DefaultAdvisorAutoProxyCreator#0'
2017-12-08 12:50:37,039 [Thread-2] DEBUG [org.springframework.beans.factory.support.DefaultListableBeanFactory] - Returning cached instance of singleton bean 'org.apache.shiro.spring.security.interceptor.AuthorizationAttributeSourceAdvisor#0'
2017-12-08 12:50:37,039 [Thread-2] DEBUG [org.springframework.beans.factory.support.DefaultListableBeanFactory] - Returning cached instance of singleton bean 'shiroFilter'
2017-12-08 12:50:37,039 [Thread-2] DEBUG [org.springframework.beans.factory.support.DefaultListableBeanFactory] - Returning cached instance of singleton bean 'org.springframework.context.support.PropertySourcesPlaceholderConfigurer#0'
2017-12-08 12:50:37,039 [Thread-2] DEBUG [org.springframework.beans.factory.support.DefaultListableBeanFactory] - Returning cached instance of singleton bean 'dataSource'
2017-12-08 12:50:37,039 [Thread-2] DEBUG [org.springframework.beans.factory.support.DefaultListableBeanFactory] - Returning cached instance of singleton bean 'org.mybatis.spring.SqlSessionFactoryBean#0'
2017-12-08 12:50:37,040 [Thread-2] DEBUG [org.springframework.beans.factory.support.DefaultListableBeanFactory] - Creating shared instance of singleton bean 'clanMapper'
2017-12-08 12:50:37,040 [Thread-2] DEBUG [org.springframework.beans.factory.support.DefaultListableBeanFactory] - Creating instance of bean 'clanMapper'
2017-12-08 12:50:37,040 [Thread-2] DEBUG [org.springframework.beans.factory.support.DefaultListableBeanFactory] - Eagerly caching bean 'clanMapper' to allow for resolving potential circular references
2017-12-08 12:50:37,042 [Thread-2] WARN [org.springframework.web.context.support.XmlWebApplicationContext] - Exception encountered during context initialization - cancelling refresh attempt
org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'clanMapper' defined in file [D:eclipse新运行环境.metadata.pluginsorg.eclipse.wst.server.coretmp1wtpwebappsZROAWEB-INFclassesapplicationContext-sql.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 'java.lang.Class' for property 'mapperInterface'; nested exception is java.lang.IllegalArgumentException: Cannot find class [ClanMapper]
at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.doCreateBean(AbstractAutowireCapableBeanFactory.java:547)
at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.createBean(AbstractAutowireCapableBeanFactory.java:476)
at org.springframework.beans.factory.support.AbstractBeanFactory$1.getObject(AbstractBeanFactory.java:302)
at org.springframework.beans.factory.support.DefaultSingletonBeanRegistry.getSingleton(DefaultSingletonBeanRegistry.java:230)
at org.springframework.beans.factory.support.AbstractBeanFactory.doGetBean(AbstractBeanFactory.java:298)
at org.springframework.beans.factory.support.AbstractBeanFactory.getBean(AbstractBeanFactory.java:193)
at org.springframework.beans.factory.support.DefaultListableBeanFactory.preInstantiateSingletons(DefaultListableBeanFactory.java:743)
at org.springframework.context.support.AbstractApplicationContext.finishBeanFactoryInitialization(AbstractApplicationContext.java:757)
at org.springframework.context.support.AbstractApplicationContext.refresh(AbstractApplicationContext.java:480)
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:4521)
at org.apache.catalina.core.StandardContext$1.call(StandardContext.java:5004)
at org.apache.catalina.core.StandardContext$1.call(StandardContext.java:4999)
at java.util.concurrent.FutureTask.run(FutureTask.java:262)
at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1145)
at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:615)
at java.lang.Thread.run(Thread.java:745)
Caused by: org.springframework.beans.TypeMismatchException: Failed to convert property value of type 'java.lang.String' to required type 'java.lang.Class' for property 'mapperInterface'; nested exception is java.lang.IllegalArgumentException: Cannot find class [ClanMapper]
at org.springframework.beans.BeanWrapperImpl.convertIfNecessary(BeanWrapperImpl.java:480)
at org.springframework.beans.BeanWrapperImpl.convertForProperty(BeanWrapperImpl.java:511)
at org.springframework.beans.BeanWrapperImpl.convertForProperty(BeanWrapperImpl.java:505)
at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.convertForProperty(AbstractAutowireCapableBeanFactory.java:1515)
at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.applyPropertyValues(AbstractAutowireCapableBeanFactory.java:1474)
at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.populateBean(AbstractAutowireCapableBeanFactory.java:1214)
at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.doCreateBean(AbstractAutowireCapableBeanFactory.java:537)
... 18 more
Caused by: java.lang.IllegalArgumentException: Cannot find class [ClanMapper]
at org.springframework.util.ClassUtils.resolveClassName(ClassUtils.java:286)
at org.springframework.beans.propertyeditors.ClassEditor.setAsText(ClassEditor.java:63)
at org.springframework.beans.TypeConverterDelegate.doConvertTextValue(TypeConverterDelegate.java:450)
at org.springframework.beans.TypeConverterDelegate.doConvertValue(TypeConverterDelegate.java:423)
at org.springframework.beans.TypeConverterDelegate.convertIfNecessary(TypeConverterDelegate.java:195)
at org.springframework.beans.BeanWrapperImpl.convertIfNecessary(BeanWrapperImpl.java:460)
... 24 more
Caused by: java.lang.ClassNotFoundException: ClanMapper
at org.apache.catalina.loader.WebappClassLoader.loadClass(WebappClassLoader.java:1643)
at org.apache.catalina.loader.WebappClassLoader.loadClass(WebappClassLoader.java:1488)
at org.springframework.util.ClassUtils.forName(ClassUtils.java:249)
at org.springframework.util.ClassUtils.resolveClassName(ClassUtils.java:283)
... 29 more
2017-12-08 12:50:37,045 [Thread-2] DEBUG [org.springframework.beans.factory.support.DefaultListableBeanFactory] - Destroying singletons in org.springframework.beans.factory.support.DefaultListableBeanFactory@7e658391: defining beans [securityManager,cacheManager,jdbcRealm,lifecycleBeanPostProcessor,org.springframework.aop.framework.autoproxy.DefaultAdvisorAutoProxyCreator#0,org.apache.shiro.spring.security.interceptor.AuthorizationAttributeSourceAdvisor#0,shiroFilter,org.springframework.context.support.PropertySourcesPlaceholderConfigurer#0,dataSource,org.mybatis.spring.SqlSessionFactoryBean#0,clanMapper,org.mybatis.spring.mapper.MapperScannerConfigurer#0,busMapper,busorderMapper,busrecordMapper,busorderService,busrecordService,busService,emp1Mapper,permMapper,emp1Service,permService,bbsMapper,deptMapper,empMapper,roleMapper,org.springframework.context.annotation.internalConfigurationAnnotationProcessor,org.springframework.context.annotation.internalAutowiredAnnotationProcessor,org.springframework.context.annotation.internalRequiredAnnotationProcessor,org.springframework.context.annotation.internalCommonAnnotationProcessor,org.springframework.context.annotation.ConfigurationClassPostProcessor.importAwareProcessor,org.springframework.context.annotation.ConfigurationClassPostProcessor.enhancedConfigurationProcessor]; root of factory hierarchy
2017-12-08 12:50:37,046 [Thread-2] DEBUG [org.springframework.beans.factory.support.DefaultListableBeanFactory] - Retrieved dependent beans for bean 'securityManager': [org.apache.shiro.spring.security.interceptor.AuthorizationAttributeSourceAdvisor#0]
2017-12-08 12:50:37,054 [Thread-2] DEBUG [org.springframework.beans.factory.support.DisposableBeanAdapter] - Invoking destroy method 'close' on bean with name 'dataSource'
2017-12-08 12:50:37,055 [Thread-2] ERROR [org.springframework.web.context.ContextLoader] - Context initialization failed
org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'clanMapper' defined in file [D:eclipse新运行环境.metadata.pluginsorg.eclipse.wst.server.coretmp1wtpwebappsZROAWEB-INFclassesapplicationContext-sql.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 'java.lang.Class' for property 'mapperInterface'; nested exception is java.lang.IllegalArgumentException: Cannot find class [ClanMapper]
at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.doCreateBean(AbstractAutowireCapableBeanFactory.java:547)
at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.createBean(AbstractAutowireCapableBeanFactory.java:476)
at org.springframework.beans.factory.support.AbstractBeanFactory$1.getObject(AbstractBeanFactory.java:302)
at org.springframework.beans.factory.support.DefaultSingletonBeanRegistry.getSingleton(DefaultSingletonBeanRegistry.java:230)
at org.springframework.beans.factory.support.AbstractBeanFactory.doGetBean(AbstractBeanFactory.java:298)
at org.springframework.beans.factory.support.AbstractBeanFactory.getBean(AbstractBeanFactory.java:193)
at org.springframework.beans.factory.support.DefaultListableBeanFactory.preInstantiateSingletons(DefaultListableBeanFactory.java:743)
at org.springframework.context.support.AbstractApplicationContext.finishBeanFactoryInitialization(AbstractApplicationContext.java:757)
at org.springframework.context.support.AbstractApplicationContext.refresh(AbstractApplicationContext.java:480)
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:4521)
at org.apache.catalina.core.StandardContext$1.call(StandardContext.java:5004)
at org.apache.catalina.core.StandardContext$1.call(StandardContext.java:4999)
at java.util.concurrent.FutureTask.run(FutureTask.java:262)
applicationContext-sql.xml 内 clanMapper 的 property 错误,应该是某个引用而不是字符串
版权声明:本文内容由阿里云实名注册用户自发贡献,版权归原作者所有,阿里云开发者社区不拥有其著作权,亦不承担相应法律责任。具体规则请查看《阿里云开发者社区用户服务协议》和《阿里云开发者社区知识产权保护指引》。如果您发现本社区中有涉嫌抄袭的内容,填写侵权投诉表单进行举报,一经查实,本社区将立刻删除涉嫌侵权内容。