首页 > Web开发 > 详细

org.apache.shiro.realm.AuthorizingRealm - No cache or cacheManager properties have been set. Authorization cache cannot be obtained.

时间:2015-02-27 11:25:14      阅读:6631      评论:0      收藏:0      [点我收藏+]

项目中用spring shiro来处理权限的问题,但是启动的时候会打印如下日志

org.apache.shiro.realm.AuthorizingRealm  - No cache or cacheManager properties have been set.  Authorization cache cannot be obtained.

检查了basicRelam配置如下

<bean id="basicRealm" class="com.ebon.platform.realm.BasicRealm" />

BasicRealm继承自AuthorizingRealm

根据提示信息可以判断未给BasicRealm指定cacheManager,所以修改如下

<bean id="basicRealm" class="com.ebon.platform.realm.BasicRealm" >
        <property name="authorizationCacheName" value="shiro-authorizationCache"/>
        <property name="cacheManager" ref="shiroCacheManager"/>
</bean>

 

org.apache.shiro.realm.AuthorizingRealm - No cache or cacheManager properties have been set. Authorization cache cannot be obtained.

原文:http://www.cnblogs.com/modprobe/p/4302675.html

(4)
(1)
   
举报
评论 一句话评论(0
关于我们 - 联系我们 - 留言反馈 - 联系我们:wmxa8@hotmail.com
© 2014 bubuko.com 版权所有
打开技术之扣,分享程序人生!