升级到Grails 2.0:找不到/index.gsp [英] Upgrade to Grails 2.0: /index.gsp not found
问题描述
我已经从Grails 1.3.7升级到2.0.0.RC1:
排除了很多与depdendencies有关的问题后,我终于设法启动了我的Grails应用程序,但浏览到URL时,它告诉我我收到以下内容:
GroovyPagesServlet:/index.gsp未找到
它在以前完美运行...它在哪里寻找它?
感谢
Jonas
由于官方文档添加SecurityFilters.groovy,同样的事情发生。 Tomcat显示错误:/index.gsp未找到
请参阅:
http://grails.org/doc/latest/guide/theWebLayer.html#filterTypes
class SecurityFilters {
def filters = {
loginCheck(controller:'*',action:'*'){
before = {
if(!session.user& amp; amp; amp; ;&!actionName.equals('login')){
redirect(action:'login')
return false
}
}
}
}
}
其实,我认为官方文件是一个错误。在
重定向(action:'login')
它应该是
返回true
I have upgraded from Grails 1.3.7 to 2.0.0.RC1:
After sorting out a lot of issues with depdendencies I have finally managed to start my Grails application but when browsing to URL it tell me I receive the following:
GroovyPagesServlet: "/index.gsp" not found
It worked perfectly before... where is it looking for it?
Thanks
Jonas
As I add SecurityFilters.groovy due to official docs, the same thing happens. Tomcat show error: "/index.gsp" not found Please see also: http://grails.org/doc/latest/guide/theWebLayer.html#filterTypes
class SecurityFilters {
def filters = {
loginCheck(controller: '*', action: '*') {
before = {
if (!session.user && !actionName.equals('login')) {
redirect(action: 'login')
return false
}
}
}
}
}
Actually, I think the official doc make a mistake. After
redirect(action: 'login')
it should be
return true
这篇关于升级到Grails 2.0:找不到/index.gsp的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!