> For the complete documentation index, see [llms.txt](https://developer.collibra.com/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://developer.collibra.com/workflows/designing-workflows/processes/process-execution/upgrading-your-scripts-for-groovy-3-compatibility.md).

# Upgrading your scripts for Groovy 3 compatibility

Groovy 3 introduces a list of breaking changes that can affect Collibra Groovy workflow scripts. You can consult the full list in the [Groovy 3 release notes](https://groovy-lang.org/releasenotes/groovy-3.0.html#Groovy3.0releasenotes-OtherBreaking). There are two breaking changes that can most likely affect Collibra workflows:

* If a Groovy switch statement has a default branch, it must be the last branch.
* Groovy is now more compliant with the JavaBeans specification for one edge case scenario involving any field having a name starting with an uppercase letter ([GROOVY-9618](https://issues.apache.org/jira/browse/GROOVY-9618)).
* Enums cannot have a non-private constructor.
* To use an interface “Function” as a parameter it must be typed, for example: `_methodHandler(Function<Integer, Integer> requiredFunction)`.

You can upgrade the workflows groovy script code to be compatible with these changes before we upgrade Collibra to the version containing Groovy 3.


---

# Agent Instructions
This documentation is published with GitBook. GitBook is the documentation platform designed so that both humans and AI agents can read, navigate, and reason over technical content effectively. Learn more at gitbook.com.

## Querying This Documentation
If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://developer.collibra.com/workflows/designing-workflows/processes/process-execution/upgrading-your-scripts-for-groovy-3-compatibility.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
