Wednesday, May 21, 2014

Master Groovy on Grails



Levels:
1.  Compare Groovy on Grails vs Play Framework
2.  Compare Groovy vs Java
3.

Learnt:
1.  Grails have many plugins, which can be installed to work with specific component. Grails is a platform, similar to Predix platform.
2.     Item             Grails Platform                            Predix Platform
     Community    Grails Community                          Company
     Plugins           Different Developers/Teams          Platform/Solution/Project Team
     Pluggable       Yes, out of box                              Yes, out of box
     Tech               Convention over configuration      OSGI
     Languages      Groovy/java
3.  Scala over Groovy  
4.

Learnt:
1.  Groovy can use Spring injection to inject service to groovy class.
2.  Groovy can map domain object to database tables.
3.  Groovy doesn't know what is the default package structure
4.  Grails support spring mvc and spring webflow
5.

Disadvantages of Grails:
1. Don't have web.xml, and difficult to add filter. Otherwise, I have to find workaround.
    Workaround: "grails run-app" == "grails -Dgrails.env=development war"
    There is a big gap between grails run-app and "mvn clean install"
    Don't use "mvn clean install" to create war, instead, use "grails war" to create war file.
    The production enviornment shall be the same as development environment.
2.  During development, I use "grails run-app"; and During deployment, I shall use "grails -Dgrails.env=development war"
3.  This is a grails project, and we shall remove the maven dependencies moving forwards. need to dig why it can resolve this.
4.

No comments:

Post a Comment