Я написал простой проект hello world с использованием весеннего ядра безопасности. В основном у меня есть контроллер с одной защищенной аннотацией.проект не был построен ... не может найти класс ... org.springframework.security.core.GrantedAuthority
package springsecuritytest
import grails.plugin.springsecurity.annotation.Secured
@Secured(['ROLE_ADMIN'])
class HelloController {
def index() {
render "this is public"
}
def logout(){
}
}
Таким образом, приложение работает правильно и работает правильно. Когда я пытаюсь получить доступ к странице индекса, он попросит меня войти в систему и только если у меня есть роль администратора, я могу получить доступ к странице.
Теперь я добавить код SimPE для выхода из системы и я получаю следующую ошибку
package springsecuritytest
import grails.plugin.springsecurity.annotation.Secured
import grails.plugin.springsecurity.SpringSecurityUtils
@Secured(['ROLE_ADMIN'])
class HelloController {
def index() {
render "this is public"
}
def logout(){
redirect uri: SpringSecurityUtils.securityConfig.logout.filterProcessesUrl
}
}
ошибка я получаю следующим образом:
The project was not built since its build path is incomplete. Cannot find the class file for org.springframework.security.core.GrantedAuthority. Fix the build path then try building this project
Я признателен за любую помощь! Благодаря!