In a previous post I showed a script that I had created to allow the execution of a groovy script within a grails application context (including access to domain objects, controllers, services, etc). A couple of people reported a problem with the script where they were getting lazy initialization exceptions. I finally tracked this issue down to one where many-to-many relationships are being used between two domain classes.
Here is an updated script that fixes this issue by setting up the hibernate session in the Gant script.
A collection of articles and resources of interest to the modern software developer
Your work is going to fill a large part of your life, and the only way to be truly satisfied is to do what you believe is great work. And the only way to do great work is to love what you do.
-- Steve Jobs
Thursday, June 23, 2011
Using Gant to execute a groovy script within the Grails context (updated) - Ted Naleid
Using Gant to execute a groovy script within the Grails context (updated) - Ted Naleid
Subscribe to:
Post Comments (Atom)
No comments:
Post a Comment