Skip to content
Alex Vigdor edited this page Oct 8, 2018 · 3 revisions

Groovity

Groovity is a JVM-based programming language and runtime engine that builds on the open-source Groovy scripting language. Groovity source files have the extension ".grvt" to distinguish them from standard groovy or grails source files, as groovity introduces new syntax and built-in functions that will not work in a standard groovy environment. Groovity was designed to support high-performance web site and REST API development, but the core language can also be used outside a servlet context, on the command line or embedded in other applications.

The key enhancements Groovity adds to Groovy include

  • Streaming template objects
  • Declarative arguments syntax for validating and coercing input from servlet requests or command line
  • Extensible tagging API to create global functions and re-usable template logic
  • Rich core tag set including HTTP/REST and WebSocket consumers and pull-through caching
  • Strict decoupling of scripts in isolated classloaders with runtime compilation and linking
  • Lifecycle enhancements including static initializers and destructors, and pre-runtime load() phase for fast failure
  • Management utilities for runtime compilation, troubleshooting, and performance profiling
  • Access to binding, tags, load and run methods from inner classes
  • Modular packaging allows composition of rich applications from reusable components

Begin your journey with Groovity on the Getting Started page

Next you should acquire an understanding of Core Concepts

Once you've covered those bases, more advanced topics are also documented

  • Caching in-depth coverage of caching
  • Http Client in-depth coverage of http client operations
  • Async in-depth coverage of multithreaded programming
  • Web Sockets using client and server web sockets
  • Traits developing classes with multiple inheritance
  • Release Notes groovity version release notes

Groovity is comprised of several different modules

  • groovity-core the basic language compiler, runtime and core tag library, can be incorporated as a library in any application
  • groovity-servlet a servlet built on groovity-core that offers simple declarative configuration of JAX-RS style URL paths, security, cors, content negotiation and more
  • groovity-maven-plugin a maven plugin allowing you run groovity scripts on the command line, to write and execute unit tests in groovity, and package compiled groovity scripts into jar or war files
  • groovity-jar-runner generate a standalone executable jar with embedded jetty server for a groovity application
  • groovity-data a data abstraction framework for scalable applications
  • groovity-events a framework for async client/server event multiplexing over a websocket
  • groovity-sample-webapp an application demonstrating how to build a REST API or web pages in a java webapp built on groovity-servlet and groovity-data
  • groovity-servlet-admin a groovity module offering cluster administration, monitoring and troubleshooting features for groovity webapps
  • groovity-sql a groovity module offering simple access to container-managed or scripted SQL datasources
  • groovity-elasticsearch a groovity-data data source implementation for Elasticsearch
  • groovity-standalone an executable jar that allows you to develop and run groovity scripts without using maven
  • groovity-portal a web portal framework built in groovity offering administration of users, groups, roles and configuration
  • groovity-sample-portal a small sample portal built using the groovity-portal framework
  • groovity-crypto a groovity module offering simple encrypt/decrypt method for working with sensitive data
  • groovity-data-service a general purpose REST API for groovity-data based models
Clone this wiki locally