• Overview
  • Documentation
  • Version history

Description

Groovy is an object-oriented programming language for the Java platform and the language of choice for writing HCL DevOps Deploy plug-ins. The DevOps Deploy agent comes with a preinstalled version of Groovy, which can be used to run your script, or you can specify a different installation.

Platform Support

  • This plug-in is supported to run on all operating systems that are supported by HCL DevOps Deploy including z/OS with UNIX System Services.
  • By default, all scripts are run against the Groovy version included with the HCL DevOps Deploy agent. For example, Groovy v1.8.8 is included with HCL Launch v6.0.1.1.

Quick Info

Product icon

Product

HCL DevOps Deploy (HCL Launch)
Plugin type icon

Type

Plug-in
Compatibility icon

Compatibility

HCL Launch v6.0 and later, HCL DevOps Deploy v8.0.0 and later.
created by icon

Created by

HCLSoftware
Website icon

Website

Published Date

Last Updated

Summary

The Groovy plug-in automates running a Groovy script as a process step. This plug-in is installed as part of HCL DevOps Deploy (Launch).

This plug-in includes one step.

  • Run Groovy Script

Installation

No special steps are required for installation. This plug-in is included with the installation of HCL DevOps Deploy. If you must install the plug-in again, see Installing plug-ins in HCL Deploy products.

Usage

You can use the Groovy plug-in to run Groovy scripts as HCL DevOps Deploy (Launch) process steps. See the Groovy website for information about creating a Groovy script.

  • Step palette
  • Examples

Step Palette

To access this plug-in in the palette, click Scripting.

Examples

You can use this plug-in to create a simple or complex step. For example, the following script obtains the date and time, formats that data, and passes it into an output variable named date. The output variable can be used in a later process step.

import java.text.SimpleDateFormat
def today = new Date()
def formattedDate = new SimpleDateFormat("yyyy-MM-dd\_hh-mm-ss").format(today)
println "Setting output property 'date' to '$formattedDate'"
println "Access the time stamp in later steps using \``${p:NameOfThisStep/date}``"
outProps.put("date",formattedDate)

Steps

Process step in the Groovy plug-in:

Run Groovy Script

This step runs a groovy script

Name Type Description Required
Groovy Home String The Groovy home directory. The default value is the GROOVY_HOME environment variable. Yes
Script String The Groovy script code to run. Use thejava.util.Properties Java variable, outProps to upload output properties to the server, and the inProps variable to contain all input properties. Yes
ClassPath String List the classpaths to include. Separate multiple classpaths using commas or new lines. No

launch-groovy-16.1155716.zip

Uploaded: 21-Apr-2023 14:12

Release Notes

  • Updating Jettison library to 1.5.4 for CVE-2023-1436.

launch-groovy-15.1150667.zip

Uploaded: 01-Feb-2023 14:31

Release Notes

  • Updating jettison library for CVE-2022-45693 and CVE-2022-45685.

launch-groovy-14.1142514.zip

Uploaded: 10-Oct-2022 16:34

Release Notes

  • Updating jettison library for CVE-2022-40150 CVE-2022-40149.

launch-groovy-12.1060531.zip

Uploaded: 17-Mar-2021 14:11

Release Notes

  • Fixed RFE 116752 - Allow Plugin to use additional classpath options.

Release Notes

  • Added the current working directory to the classpath of the child process to support executing script files.

Release Notes

  • Added Shutdown Hook to ensure Output Properties are set on script exit.
  • If Shutdown Hooks exist in your Groovy scripts, there may be conflicts or inconsistencies in Shutdown Hook order and behaviour.

Release Notes

  • Support property file encryption.

Release Notes

  • Added support for encrypted property files.

Release Notes

  • Includes translated content.

r

Release Notes

  • This release includes fixing a defect related to running Groovy on Microsoft Windows.

Release Notes

  • Complete plugin overhaul. The script is now wrapped in another Groovy script instead of using GroovyShell. The Groovy Home now properly overrides the agent's value.

Release Notes

  • Fixes APAR PI35342 - compatibility defect with HCL Launch version 6.1.0.4 and later.

Release Notes

  • Groovy steps can now run JUnit test cases.

Release Notes

  • Added a Groovy Home property to set the GROOVY_HOME value to use when running scripts.

Release Notes

  • Loading the Groovy plugin will give users access to a Groovy step that allows the execution of scripts.

Related Plugins