5. What is Groovy ?
Is an agile and dynamic language for the Java Virtual Machine
Makes modern programming features available to Java developers
with almost-zero learning curve
Increases developer productivity
Compiles straight to Java bytecode so you can use it anywhere you
can use Java
Seamlessly integrates with all existing Java classes and libraries
6. What is Grails?
Full stack MVC framework for web apps
Exploits the awesome power of Groovy
Leverages proven staples
– Hibernate
– Spring
– Sitemesh
Works on JVM
8. Why GRAILS?
Java web development as it stands today is
dramatically more complicated than it needs
to be
Most modern web frameworks in the Java
space are over complicated and don't
embrace the Don't Repeat Yourself (DRY)
principles.
9. Why GRAILS?
- An easy to use Object Relational Mapping (ORM)
layer built on Hibernate
- An expressive view technology called Groovy Server
Pages (GSP)
- A controller layer built on Spring MVC
- A transactional service layer built on Spring's
transaction abstraction
10. Why GRAILS?
Based on battle tested and proven Java frameworks (Spring,
Hibernate, SiteMesh, Quartz, etc)
Based on Groovy language
GORM(Grails Object Relational Mapping)
Doesn’t stop you from using the power of underlying frameworks
Easy to set-up and get started
Minimal server restart required while development
Convention over Configuration / No painful XML configuration &
XML Management
Tag Lib Authoring mechanism
Tons of available plugins
11. Convention Over Configuration
Grails uses "convention over configuration" to configure itself
This typically means that the name and location of files is used
instead of explicit configuration
No config files
No action mappings
12. GRAILS AND SECURITY
All standard database access via GORM domain objects is
automatically SQL escaped to prevent SQL injection attacks
Grails link creating tags (link, form, createLink, createLinkTo and
others) all use appropriate escaping mechanisms to prevent code
injection
Grails provides codecs to let you trivially escape data when rendered
as HTML, JavaScript and URLs to prevent injection attacks here.
XSRF attacks prevention with useToken
20. Dynamic Finders
def book = Book.findByTitle("The Stand")
book = Book.findByTitleLike("Harry Pot%")
book = Book.findByReleaseDateBetween(firstDate, secondDate)
book = Book.findByReleaseDateGreaterThan(someDate)