我正在做一个使用Apache Shiro进行安全性保护的grails项目。编译或运行应用程序时收到此警告。
Note: /../shiro/grails/LegacyShiroFilter.java uses or overrides a deprecated API.
Note: Recompile with -Xlint:deprecation for details.
BuildConfig.groovy
plugins {
build ":tomcat:7.0.55"
compile ":scaffolding:2.1.2"
compile ':cache:1.1.8'
compile ":asset-pipeline:1.9.9"
runtime ":hibernate4:4.3.6.1" // or ":hibernate:3.6.10.18"
runtime ":database-migration:1.4.0"
compile ":shiro:1.2.1"
}
有任何想法吗?在此先感谢您的帮助。
最佳答案
LegacyShiroFilter
扩展了已弃用的org.apache.shiro.web.servlet.IniShiroFilter
。如果您转到plugin's page at grails.org,您将看到插件源的链接,您可以在其中阅读类Javadoc(或在插件安装目录中阅读该类),其内容如下:
Its only reason for existence is to support the legacy
security.shiro.filter.config
setting
这是described in the release notes
the security.shiro.filter.config setting is deprecated in favour of security.shiro.filter.filterChainDefinitions + other configuration options. It will continue to work though.
关于grails - 利用Apache Shiro的Grails项目:LegacyShiroFilter使用或覆盖已弃用的API,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/27853561/