© Adam L. Davis 2019
Adam L. DavisLearning Groovy 3https://doi.org/10.1007/978-1-4842-5058-7_11

11. Groovy Awesomeness

Adam L. Davis1 
(1)
New York, NY, USA
 

This short chapter introduces various useful frameworks within the Groovy ecosystem. Some of these will be described more fully in later chapters.

Web and UI Frameworks

The following are web and user interface frameworks that are built on top of Groovy or where Groovy is supported.

Grails1

A web framework inspired by Ruby on Rails. It has at least 800 plugins and uses convention over configuration approach.

Micronaut2

A newer framework for building microservices, serverless applications, or command-line applications with a small memory footprint and fast start-up speed with compile-time annotation processing. Built by the same group behind Grails.

Griffon3

A framework for building Swing UIs. It has a command-line interface very similar to Grails. For example, create-app cool -archetype=jumpstart.

Vert.x4

A framework for asynchronous application development. Not strictly a Groovy project, but you can use it. It’s currently an Eclipse Foundation project.5

Ratpack6

A toolkit for asynchronous web applications on the JVM and web services (microservices). Built on top of Netty.

Cloud Computing Frameworks

Cloud computing has become a mainstream necessity in today’s programming world. Here are two useful Groovy frameworks for two popular cloud platforms.

Gaelyk7

An abstraction over GAE (Google App Engine); it has an emerging plugin system.

Caelyf8

Apache 2-licensed framework for CloudFoundry. It’s similar to gaelyk.

Build Frameworks

No project is complete without a build framework. Gradle has become more and more popular in the last few years especially for building Java projects. It’s also the default build framework for Android and Grails projects.

Gradle9

It uses a Groovy-based DSL for building projects (it has added a Kotlin-based DSL as well) and uses build.gradle as the main build file. It has a very large plugin ecosystem and can be used to build any type of application.

Gant10

Like Ant in Groovy. It’s now in maintenance mode. It was used by Grails and Griffon in the past.

Testing Frameworks/Code Analysis

Testing is extremely important for any project, and code analysis is sometimes useful for large projects. We will cover one of these frameworks, called Spock, in a later chapter.

Spock11

A very slick Groovy-based DSL testing framework that has been around for many years. It has the ability to use data tables for test input, built-in ability to mock classes and interfaces, and many other features.

Codenarc12

Static code analysis for Groovy and has been around since 2009. It has plugins for Grails and Griffon.

Concurrency

As described earlier, concurrency is extremely important for efficient applications to take complete advantage of the hardware.

GPars13

A multi-threading framework for Groovy. It has a fork/join abstraction, Actors, Dataflow, STM, and more.

RxGroovy14

This is a Groovy adapter to RxJava, a library for composing asynchronous and event-based programs using observable sequences for the JVM. However, it’s no longer necessary—you can just use the RxJava library directly.

Others

These are other tools created by the community for managing your installed programming frameworks and tools and for creating new projects.

SDKMAN15

Originally called Groovy enVironment Manager (GVM). It’s now called SDKMAN (Software Development Kit Manager) and is very cool. It allows you to manage multiple versions of several Groovy and non-Groovy SDKs, including Groovy itself.

Lazybones16

A simple project creation tool that uses packaged project templates. This can be installed using sdkman. It creates the basic files necessary to start various types of projects. For example, it has a Ratpack template.

GrooCSS17

A Groovy-based DSL for creating CSS. It’s much like LESS but with everything Groovy has to offer available.

..................Content has been hidden....................

You can't read the all page of ebook, please click here login for view all page.
Reset