I just update my app to grails 3.3.10. It's a simple app that use spring security 3.2.3. My url map is this:
class UrlMappings {
static mappings = {
"/$controller/$action?/$id?(.$format)?" {
constraints {
// apply constraints here
}
}
"/"(controller: "home", action: "index")
"500"(controller: "error", action: "error500", [params: params])
"404"(view: '/error/notFound')
}
}
after update from 3.3.9 to 3.3.10 the / is not anymore redirect to home controller. If I roll back it then it works again. Documentation on grails web site has a broken link for 3.3.10 version. They change something or it sounds to me it's a bug. Any ideas?
UPDATE thanks to @MiloBen I did a step forward, and now I it seems to be redirect to home but now I got a 403 in the home page. Let me recap. My UrlsMapping.groovy is the same, see above. My application.groovy is this now:
[pattern: '/', access: ['permitAll']],
[pattern: '/error', access: ['permitAll']],
[pattern: '/login/**', access: ['permitAll']],
[pattern: '/assets/**', access: ['permitAll']],
[pattern: '/home/**', access: ['permitAll']]
I cannot figure out what is the problem now, it seems permitAll should kick in and let me see my home page /home, which is redirected in / by the UrlMapping.
I had similar issue.
In the file grails-app/conf/application.groovy
I found these lines:
[pattern: '/index', access: 'permitAll'],
[pattern: '/index.gsp', access: 'permitAll'],
I did not have index.gsp
file the lines referred to, but it somehow worked in grails 3.3.8
and started failing in 3.3.10
. Removing those two lines fixed my issue.
I had the same issue because I had an index.gsp left over from the original creation. Deleting the index.gsp allowed my home route to work.
I also had a similar issue and resorted to using grails 3.3.9 for now.
It is a known issue and there is a fix in the newest snapshot version.
The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.