Code Bye

Error creating bean with name 'shiroFilter': Requested

Error creating bean with name “shiroFilter”: Requested bean is currently in creation: Is there an unresolvable circular reference?
<!-- Shiro Filter -->
	<bean id="shiroFilter" class="org.apache.shiro.spring.web.ShiroFilterFactoryBean" >
		<property name="securityManager" ref="securityManager" />
		<property name="loginUrl" value="/login.jsp" />
		<property name="successUrl" value="/rms/main/login.do" />
		<property name="filters">
			<map>
            	<entry key="loginfilter" value-ref="loginFilter"/>
        	</map>
		</property>
		<property name="filterChainDefinitions">
			<value>

				/=anon
				/services/**=anon
				/mobileservices/**=anon
				/rms/login/checkUser** =anon
				/schedule/** =anon
				/web/map/** =anon
				/mobileVersions/** =anon
				/rms/login/** = loginfilter
				/android/** = anon
				/servlet/UploadImageServlet = anon
				/js/** = anon
				/css/** = anon
				/common/** = anon
				/images/** = anon
				/pages/** = anon
				/DoTimerTask.jsp = anon
				/handDo/** = anon
				/apk/** = anon

				/web/rms/task/addTask.jsp =perms[RMS0051]
				 
				/** = loginfilter

		 	</value>
		</property>
<description>Shiro Configuration</description>
	<!-- 項目自定义的Realm -->
	<bean id="accountManager" class="com.sinosoft.rms.client.AccountManagerLocalImpl">
	</bean>

	<!-- Shiro"s main business-tier object for web-enabled applications -->
	<bean id="securityManager" class="org.apache.shiro.web.mgt.DefaultWebSecurityManager">
		<property name="realm" ref="shiroDbRealm" />
		<property name="cacheManager" ref="cacheManager" />
	</bean>

	<bean id="shiroDbRealm" class="com.sinosoft.rms.client.shiro.ShiroDbRealm" depends-on="rmsClientService" >
		<property name="accountManager" ref="accountManager"/>
		<property name="credentialsMatcher" ref="credentialsMatcher"></property>
	</bean>
	<!-- MD5认证 -->
	<bean id="credentialsMatcher" class="org.apache.shiro.authc.credential.Md5CredentialsMatcher"></bean>
	<!-- 用户授权信息Cache -->
	<bean id="cacheManager" class="org.apache.shiro.cache.MemoryConstrainedCacheManager" />

	<!-- 保证实现了Shiro内部lifecycle函数的bean执行 -->
	<bean id="lifecycleBeanPostProcessor" class="org.apache.shiro.spring.LifecycleBeanPostProcessor"/>

	<bean class="org.apache.shiro.spring.security.interceptor.AuthorizationAttributeSourceAdvisor">
    	<property name="securityManager" ref="securityManager"/>
	</bean>
解决方案

80


CodeBye 版权所有丨如未注明 , 均为原创丨本网站采用BY-NC-SA协议进行授权 , 转载请注明Error creating bean with name 'shiroFilter': Requested