Java Reference
In-Depth Information
of the coauthors of Groovy in Action (Manning, 2007) and an outstanding developer, as a
helpful reference. [ 7 ]
7 I'll just say it here: everything Paul King says is right. Start with that assumption and you'll be fine.
Groovy has other classes that support server-side configuration, like ServletBinding ,
which extends the regular script Binding class.
Lessons learned (testing)
1. Spring provides a library of mock objects for unit-testing web applications. The
same library is built into Grails.
2. The web and Jetty plugins in Gradle make it easy to build and deploy web applic-
ations. With some work, Gradle can do automatic integration testing.
Larger applications require more structure to be easily maintainable. The Java world is full
of web frameworks, from Struts (both versions 1 and 2) to Tapestry to Wicket to JSF to
Spring MVC and more. In the Groovy world, one particular framework is dominant, to the
point of attracting developers to Groovy just so they can use this framework. That's the
definition of a killer app: an application so cool people will learn a new language just to
use it. That framework, as most readers well know, is called Grails.
This is a book about using Java and Groovy together, so I won't present a standard tutorial
on how to get started with Grails. There are plenty of references for that available. [ 8 ] In-
stead, I'll show a simple, but hopefully nontrivial, application, discuss some of the archi-
tectural choices made when creating Grails, and show how existing Java classes can be in-
corporated into a Grails application.
8 See especially the excellent Grails in Action , by Peter Ledbrook and Glen Smith (Manning, 2009).
 
 
Search WWH ::




Custom Search