码迷,mamicode.com
首页 > Web开发 > 详细

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

时间:2015-02-27 11:27:03      阅读:907      评论: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

(0)
(0)
   
举报
评论 一句话评论(0
登录后才能评论!
© 2014 mamicode.com 版权所有  联系我们:gaon5@hotmail.com
迷上了代码!