Understanding Groovy for Orchestration Components

In the Orchestrator Studio, programmers can use Apache Groovy, a scripting language for the Java platform, to extend the functionality of orchestrations. In the Orchestrator Studio, you can use Groovy to:

  • Create a custom service request that uses complex logic to perform transactions that cannot be configured in a standard service request.

  • Create a custom rule with complex conditions that cannot be configured in a standard rule.

  • Manipulate output from a REST connector response. For example, if an orchestration with a REST connector service request returns information in XML format, you can convert it to JSON for output mapping.

  • Manipulate the output from an orchestration response.

Using Groovy scripts has two advantages over using custom Java. First, the Orchestrator Studio provides an editing window for creating the Groovy script, so you do not have to use an external editor to create and test your custom program. The editing window contains a Groovy template that you can use to help get you started. Second, the Orchestrator includes the Groovy script natively as part of the orchestration, so you do not have to deploy a custom program like you do with custom Java. The Groovy script simply executes as part of the orchestration.