spring mvc项目之前能正常启动

谢谢各位大神,现在启动报错,以前能解决,现在解快不了,网上的方法都试过
[q] 2016-08-08 09:11:14 ERROR - Context initialization failed
org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'shiroFilter' defined in URL [file:/E:/newworkspace/.metadata/.plugins/org.eclipse.wst.server.core/tmp0/wtpwebapps/q-2.2-ldd/WEB-INF/classes/applicationContext-shiro.xml]: Cannot resolve reference to bean 'securityManager' while setting bean property 'securityManager'; nested exception is org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'securityManager' defined in URL [file:/E:/newworkspace/.metadata/.plugins/org.eclipse.wst.server.core/tmp0/wtpwebapps/q-2.2-ldd/WEB-INF/classes/applicationContext-shiro.xml]: Cannot resolve reference to bean 'authenticationRealm' while setting bean property 'realm'; nested exception is org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'authenticationRealm': Injection of resource dependencies failed; nested exception is org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'adminServiceImpl': Injection of resource dependencies failed; nested exception is org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'adminDaoImpl': Injection of persistence dependencies failed; nested exception is org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'entityManagerFactory' defined in URL [file:/E:/newworkspace/.metadata/.plugins/org.eclipse.wst.server.core/tmp0/wtpwebapps/q-2.2-ldd/WEB-INF/classes/applicationContext.xml]: Invocation of init method failed; nested exception is org.hibernate.AnnotationException: Unknown mappedBy in: com.iclnetwork.web.entity.InvestmentEntity.recovery, referenced property unknown: com.iclnetwork.web.entity.RecoveryEntity.investment
at org.springframework.beans.factory.support.BeanDefinitionValueResolver.resolveReference(BeanDefinitionValueResolver.java:329)
at org.springframework.beans.factory.support.BeanDefinitionValueResolver.resolveValueIfNecessary(BeanDefinitionValueResolver.java:107)
at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.applyPropertyValues(AbstractAutowireCapableBeanFactory.java:1387)
at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.populateBean(AbstractAutowireCapableBeanFactory.java:1128)
at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.doCreateBean(AbstractAutowireCapableBeanFactory.java:519)
at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.createBean(AbstractAutowireCapableBeanFactory.java:458)
at org.springframework.beans.factory.support.AbstractBeanFactory$1.getObject(AbstractBeanFactory.java:295)
at org.springframework.beans.factory.support.DefaultSingletonBeanRegistry.getSingleton(DefaultSingletonBeanRegistry.java:223)
at org.springframework.beans.factory.support.AbstractBeanFactory.doGetBean(AbstractBeanFactory.java:292)
at org.springframework.beans.factory.support.AbstractBeanFactory.getBean(AbstractBeanFactory.java:198)
at org.springframework.context.support.AbstractApplicationContext.registerBeanPostProcessors(AbstractApplicationContext.java:753)
at org.springframework.context.support.AbstractApplicationContext.refresh(AbstractApplicationContext.java:464)
at org.springframework.web.context.ContextLoader.configureAndRefreshWebApplicationContext(ContextLoader.java:389)
at org.springframework.web.context.ContextLoader.initWebApplicationContext(ContextLoader.java:294)
at org.springframework.web.context.ContextLoaderListener.contextInitialized(ContextLoaderListener.java:112)
at org.apache.catalina.core.StandardContext.listenerStart(StandardContext.java:4994)
at org.apache.catalina.core.StandardContext.startInternal(StandardContext.java:5492)
at org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:150)
at org.apache.catalina.core.ContainerBase$StartChild.call(ContainerBase.java:1575)
at org.apache.catalina.core.ContainerBase$StartChild.call(ContainerBase.java:1565)
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)

5个回答

应该是你的拦截器配置有问题

Bear_861110453
cug_xy 建议检查一下配置文件 和 Dao层的代码注释是不是改动了
接近 4 年之前 回复
Bear_861110453
cug_xy 回复qq_34597337: 拷贝是只拷贝了代码吗?还是直接导入的?
接近 4 年之前 回复
qq_34597337
qq_34597337 项目是copy过来的,运行了很长时间没有问题,这次关机启动后就一直报这个错了
接近 4 年之前 回复

拷贝是只拷贝了代码吗?还是直接导入的?

Bear_861110453
cug_xy 回复qq_34597337: 推荐博客 http://blog.csdn.net/yangkai_hudong/article/details/8940402
接近 4 年之前 回复
Bear_861110453
cug_xy 那 如果有更改的话 很有可能是单词拼写错误 甚至有可能是大小写 我上次的错误就是这样 自己仔细检查 并记得养成备份代码的好习惯
接近 4 年之前 回复
qq_34597337
qq_34597337 是直接导入的
接近 4 年之前 回复

g bean with name 'adminServiceImpl': Injection of resource dependencies failed; nested exception is org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'adminDaoImpl': 检查一下这两个类

qq_34597337
qq_34597337 ok,3q啦
接近 4 年之前 回复

虽然报的是shiroFilter这个错,但有的时候不是这个原因造成的,你新加的代码肯定有不对的地方

qq_34597337
qq_34597337 ok,3q啦,的确不是shiroFilter这个错
接近 4 年之前 回复

你是不是不止导入了一次,而且导入之后发布了不止一次?

Csdn user default icon
上传中...
上传图片
插入图片
抄袭、复制答案,以达到刷声望分或其他目的的行为,在CSDN问答是严格禁止的,一经发现立刻封号。是时候展现真正的技术了!
立即提问
相关内容推荐