ALTERthought Blogs

31 July 2008

Grails 1.0.3 upgrade issues

Recently, we upgraded our application running in Grails 1.0.1 to 1.0.3. Just to give you an idea, the application is pretty complicated involving multiple data sources, complex hibernate mappings with JPA annotations, legacy system, linking tons of external services etc. We had to overcome few significant hurdles to get our application to run in Grails 1.0.3.

1. Update hibernate-entitymanager.jar (3.3.2 GA) in project/lib

2. Add hibernate-validator.jar (3.0.0 GA) in project/lib. Grails 1.0.1 did not require this jar

3. Changes to g:render taglib.
<g:render template=”templates/my_template.gsp” /> used to work in Grails 1.0.1 with template file in _templates/my_template.gsp under grails-app/views/mycontroller/. Now, for Grails 1.0.3 you need to have the template in template/_my_template.gsp.

4. Issues with domain properties.
my_domain.properties = another_domain.properties. This doesn’t work anymore in Grails 1.0.3, at least in some cases. Had to manually copy properties.

5. There are definitely issues with complex hibernate mapping involving legacy system. A particular hibernate relationship was throwing javax.persistence.PersistenceException with Grails 1.0.3. We couldn’t figure out the actual reason, had to make the relationship transient and manually manage it.

6. Changes to taglib g:actionSubmitImage. The following works fine in Grails 1.0.1.
<g:form name="myForm" action="myAction">
<g:actionSubmitImage value="Show" xsrc=".." mce_src=".." />
</g:form>

In Grails 1.0.3, you will need to change to <g:actionSubmitImage value=”Show” xsrc=”..” mce_src=”..” action=”myAction” />

7. Issues with blank spaces in directories in Windows: This is the nasty one and can drive you crazy. You may have problems running the app or executing tests. Errors such as java.util.zip.ZipException: The system cannot find the path specified or error trying to scan etc could be noticed. These errors are due to blank spaces in JAVA_HOME(c:\Program Files\..) and user.home (c:\Documents and Settings\..). To fix this:

Grails 1.0.3 seems much faster than Grails 1.0.1 and is probably worth the trouble.

Note: This post was originally posted in the author’s blog.

Technorati Tags: , , , , ,

Post to Twitter Post to Delicious Post to Digg Post to Reddit

11 Comments currently posted.

Geertjan says:

Yes, I’ve found Grails 1.0.3 to be MUCH faster.

Shawn Hartsock says:

I did this recently as well. I found it to be a noticeable speed boost. 1.0.3 it’s worth the effort.

Darren Yafai says:

this ALTERthought Blogs » Grails 1.0.3 upgrade issues seems to have ended up saving me a ton of time in looking for a genuine reputable read in detail

HtcMerge Apps says:

Hey! This is kind of off topic but I need some help from an established blog. Is it very hard to set up your own blog? I’m not very techincal but I can figure things out pretty fast. I’m thinking about creating my own but I’m not sure where to begin. Do you have any ideas or suggestions? Thank you

Tires Cheap says:

I really like your writing style, fantastic information, thanks for putting up :D.

Valeria Giallo says:

I simply wanted to compose a simple comment to be able to thank you for some of the stunning points you are writing on this website. My extended internet investigation has at the end been recognized with beneficial tips to share with my pals. I ‘d declare that we readers are truly endowed to dwell in a really good website with so many perfect people with good solutions. I feel extremely privileged to have used the web page and look forward to plenty of more brilliant minutes reading here. Thanks a lot once more for everything.

Ginger Fisher says:

Unquestionably believe that which you said. Your favorite justification seemed to be on the web the simplest thing to be aware of. I say to you, I definitely get irked while people consider worries that they plainly do not know about. You managed to hit the nail upon the top and defined out the whole thing without having side-effects , people could take a signal. Will probably be back to get more. Thanks

JOCURI SLOT says:

its firs date to this blog, its nice ! keep work…..

Eusebio Flagg says:

Thumbs up for this great post!!!
Torik (Astigmatik) Lens

Hershel Bumm says:

How to install a custom blog design while using ftp publishing?

Gay Condoms says:

I have read a few good stuff here. Definitely value bookmarking for revisiting. I surprise how much attempt you place to make this kind of great informative website.

Post a comment on this entry: