Overriding Groovy Script Execution Method

From Addons configurations, it is possible to configure Groovy scripts execution to take place either outside or inside of Squore Server JVM by using the forkProcess attribute (Repository Connectors and Custom Tabs).

This behavior can be overridden at server level, using options from Administration > System page, in the Configuration tab and Groovy Scripts Execution section. Two parameters are available:

  • Force Groovy scripts to run in a separate process (default: false), to override any specific addons configuration that would use the forkProcess attribute, by forcing every Groovy scripts to run in a separate process (i.e. outside of Squore Server JVM).

  • Maximum number of separate processes (default: 4), to configure the maximum number of separate processes that can be run simultaneously to avoid machine overload. Groovy scripts that uses the same Java classpath will be executed in the same process. A new process will be created only if the Java classpath of the executed script is different from the ones of the running processes.