Groovy and Grails
-
Upload
gilttech -
Category
Technology
-
view
8.627 -
download
3
description
Transcript of Groovy and Grails
![Page 1: Groovy and Grails](https://reader036.fdocuments.in/reader036/viewer/2022080210/554dbd56b4c905bd488b4a43/html5/thumbnails/1.jpg)
Groovy & Grails Jean Barmash
CTO, EnergyScoreCards www.meetup.com/grails
![Page 2: Groovy and Grails](https://reader036.fdocuments.in/reader036/viewer/2022080210/554dbd56b4c905bd488b4a43/html5/thumbnails/2.jpg)
Java: String[] names = new String[] {"Rod", "Carlos", "Chris"}
for (String it : names) if (it.length() <= 4) System.out.println(it);
Groovy: String[] names = [ "Rod", "Carlos", "Chris" ]
for (String it : names) if (it.length() <= 4) System.out.println(it);
Idiomatic Groovy: names = ["Rod", "Carlos", "Chris"]
names.grep { it.size() <= 4 }.each{ println it }
![Page 3: Groovy and Grails](https://reader036.fdocuments.in/reader036/viewer/2022080210/554dbd56b4c905bd488b4a43/html5/thumbnails/3.jpg)
Groovy Language
Dynamic Language for the JVM Native Integration with Java, cross-compilation Almost-zero learning curve can rename .java to .groovy Backed by VMWare / SpringSource Open Source, Apache License Unfortunate Name
![Page 4: Groovy and Grails](https://reader036.fdocuments.in/reader036/viewer/2022080210/554dbd56b4c905bd488b4a43/html5/thumbnails/4.jpg)
Major Features
Less Ceremony Closures Native collection syntax / processing Many Features for DSL Abstract Syntax Tree Transformation
E.g. @Immutable, @Singleton Trivial XML / HTML / JSON Processing Fun Did I say easy integration with Java?
![Page 5: Groovy and Grails](https://reader036.fdocuments.in/reader036/viewer/2022080210/554dbd56b4c905bd488b4a43/html5/thumbnails/5.jpg)
Grails (www.grails.org)
High Productivity Web Framework Convention over configuration Built on solid Java technologies
Spring, Hibernate, Quartz GORM - Works with Hibernate, JPA, and NoSQL Dbs Plugins - 699 plugins & growing (including clojure, scala) IDE Support 2.0 In November Backed by SpringSource / VMWare Awesome Community Unfortunate Name
![Page 6: Groovy and Grails](https://reader036.fdocuments.in/reader036/viewer/2022080210/554dbd56b4c905bd488b4a43/html5/thumbnails/6.jpg)
Who Uses Groovy / Grails Netflix (Internally) Sky.com LinkedIn Conde Naste (Wired) Example - clickOnero in Latin America
1.5 million users, 80k concurrent users, 8 tomcats, 5 Linux boxes, 1 mysql, 1 terracotta, 1 rabbitmq
EnergyScoreCards :-)
![Page 7: Groovy and Grails](https://reader036.fdocuments.in/reader036/viewer/2022080210/554dbd56b4c905bd488b4a43/html5/thumbnails/7.jpg)
Other Groovy Projects
Spock Testing Framework GEB Functional Testing Framework GPARS - Concurrency Framework Gradle - convention over configuration build framework Griffon - Swing Framework Some Other projects that offer Groovy support
o Spring, Mule, NanoContainer, ServiceMix, Magnolia CMS, eXo, neo4j, Jenkins,
o Many more at http://groovy.codehaus.org/Related+Projects
![Page 8: Groovy and Grails](https://reader036.fdocuments.in/reader036/viewer/2022080210/554dbd56b4c905bd488b4a43/html5/thumbnails/8.jpg)
References
Groovy Home Page http://groovy.codehaus.org/ Related Projects http://groovy.codehaus.org/Related+Projects Blogs - http://groovyblogs.org/ Groovy Magazine - http://www.groovymag.com Grails - www.grails.org Grails Plugins - http://grails.org/plugin/category/all SpringSource - www.springsource.com Groovy / Grails Support
http://www.springsource.com/support/groovyandgrailssupport Conferences - Gr8Conf, SpringOne2GX SpringOne2GX - http://www.springone2gx.com/ Gr8Conf - http://www.gr8conf.org/ NYC Groovy/Grails Meetup - http://www.meetup.com/grails/