Blog
Grails 2.3.0 Redirects In URL Mappings
24 Sep, 13

Grails 2.3.0 Redirects In URL Mappings

Prior to Grails 2.3.0 redirects were not supported in URL Mappings and the available solutions were not DRY. There have been various discussions on stackoverflow, Mailing List , Jira and on the blogs to add redirect in URLMapping.groovy. Grails team has finally added...
Read file in Grails service
23 Sep, 13

Read file in Grails service

Whenever I required to put  file in Application and read content from that file I create a directory e.g. resources in the web-app directory and read content in service like: [php]import org.codehaus.groovy.grails.web.context.ServletContextHolder as SCH class...
Capture login event in grails
23 Sep, 13

Capture login event in grails

There are several use cases where we are require to capture the login event such as storing the login history, set user related data like name and email in session(so that no database hit to get this basic information), etc. In my project I asked to maintain user...
Convert string params to list
23 Sep, 13

Convert string params to list

Grails 2.x added a new method in params object “list”. This method is used in case you are not sure weather you got a string(single request parameters of a name) or a list(multiple request parameters of the same name) in params. This method always return a...