What are the Grails advantages over other Java Web Frameworks?

后端 未结 3 1400
既然无缘
既然无缘 2021-02-03 10:59

I\'ve worked with JSF, Spring MVC and Struts and I think I got a good level on these frameworks. Recently I heard that many good developers I worked with are learning Grails and

3条回答
  •  情歌与酒
    2021-02-03 11:24

    Grails adds Groovy goodness to existing Java frameworks and provides the tooling to use it easily:

    • Grails (web part) = Groovyfied Spring MVC (like @Jon points out)
    • GORM = Groovyfied Hibernate
    • GroovyTestCase = Groovyfied JUnit TestCase

    @Jon already mentioned some concrete practical advantages. I would like to point out two more fundamental concepts in the Grails approach:

    1. Convention over configuration. If you adhere to the conventions set out by Grails (which are very sensible btw) you can become productive very quickly.
    2. Don't Repeat Yourself (DRY) Grails enables you to write DRY code and in itself is a good example of how to be DRY. If you have any existing Java code reusing it in Grails should be no problem.

    So,

    Is it worth learning?

    I think for you yes. Since you already know Java and some of the available frameworks (especially Spring MVC) the learning curve should not be steep at all.

    What is all the buzz around Grails, is it only because of Groovy?

    The buzz could be explained because Grails demonstrates that Groovy can be leveraged to create a very usable "product".

提交回复
热议问题