|
CODE: GROOVY-DSL-01-02 DURATION: 2 DAY/S
Domain Specific Languages are gaining a well-deserved reputation for helping you write good, testable and clean code. By using a DSL you can drastically reduce the amount of code necessary to complete a common task. However the power of DSLs is not the domain (pun intended) of a few select framework developers; the real payback comes when you harness that power for your own domain’s needs by creating your own DSLs.
In this 2-day "Deep Dive DSLs with Groovy workshop", you will get a firm foundation of what a DSL is, know the common DSL's that we use in Groovy today, and how and when to create your own DSLs in Groovy. We will cover an extensive list of Groovy techniques when using and building DSLs, drawing inspiration from practical examples of real-world Groovy DSLs.
These techniques will range from intermediate to advanced.
This "Deep Dive DSLs with Groovy workshop" is all about harnessing that payback and so through hands-on, practical coding you will learn how to use and create DSLs that drastically improve the quality of your code, reduce maintenance and increase your productivity.
LEARN HOW TO:
- Use of some of the most popular DSLs in Groovy and Grails.
- Design a DSL in Groovy.
- Pick an appropriate Groovy implementation technique for your freshly baked DSL.
- Implement and test your production-ready DSL.
- Integrate and use your DSL from your applications.
PROGRAMME
The workshop will cover the following:
- Overview of DSL’s
- Compare and contrast the use of DSL’s (internal vs external, practical use etc)
- Internal vs External
- Improve readability of code/ bind domain language into the code using Fluent language techniques.
- When to build a DSL.
- How to test a DSL
- Cost of maintenance
- Examination of different Groovy DSL’s in current use and how they are implemented
- Spring Application Context BeanBuilder
- Spock
- Geb (WebDriver)
- Grails GORM.
- Gradle
- Maven 3 Groovy DSL.
- In depth on different Groovy techniques/ technologies that can be used to make DSLs
- Groovy Syntax improvements
- Builders
- Runtime Meta Object Protocol (MOP), Mixins, Categories, methodMissing etc.
- Compile time MOP, AST Transformations, Mixins, Categories.
- Groovy DSLs integration techniques
- Managing and organising DSL scripts
- JSR 223: Java Scripting API
- GroovyShell and GroovyClassLoader
- Spring integration (lang namespace)
This is a very interactive workshop, with frequent break outs into small groups to investigate the techniques presented.
|
ABOUT THE AUTHOR
|
Russ Miles is CEO, founder and principal consultant at OpenCredo. At OpenCredo he leads a company of passionate open source and agile and lean software development experts who provide unbiased, honest arbiter advice across a wide and varied selection
More about Russ Miles
|
IN PARTNERSHIP WITH OPENCREDO
IS THIS COURSE FOR YOU?
If you are interested in how DSLs can super-charge your productivity and clean up your code by being able to evaluate existing and even creating your own DSL’s in Groovy, then this Deep Dive DSL with groovy workshop is for you!
COURSE PREREQUISITES
This workshop covers subjects at different levels, from intermediate to advanced.
To benefit from this DSL with Groovy course you should have a workable knowledge of Groovy prior to attending.
Especially :
- Dynamic languages (dynamic dispatch)
- A basic understanding of a MetaClass.
- Closures.
As a good foundation for this course, we recommend participating in Dierk Koenig's Practical Groovy for Developers course. However this is a recommendation and not a mandatory prerequisite.
COURSE LABS & EXERCISES
Expect to be coding from the get-go, and bringing your own Laptops is certainly recommended! In terms of IDEs, whatever you are comfortable with when working on Groovy code should be absolutely fine.
If you prefer to be provided with a laptop please let us know prior to the course and we'll be happy to facilitate this.
|