Script value

See also: Scripted rule, Script (Event action)

Value resover – Abstract

Purpose: Delivers the return value of a BeanShell script defined to the configuration.


The use of Bean Shell scripts in Lobster Data Platform / Orchestration requires advanced programming skills and profound knowledge of system internals.

images/s/-95e2zf/9012/8yg2g7/_/images/icons/emoticons/warning.svg Improper use of script may cause severe and irreversible damage to the system and data contained images/s/-95e2zf/9012/8yg2g7/_/images/icons/emoticons/warning.svg

Bean Shell scripts are used exclusively to meet requirements that are so special they cannot be covered by any of the generic configuration options available.

Please contact Lobster Data Platform / Orchestration support by support@scm.lobster.de for further information or to learn about options for training or workshops.

images/download/attachments/62851638/image2022-9-28_10-47-33-version-1-modificationdate-1664354853606-api-v2.png

The Script value resolver returns the return value of a BeanShell script.

The following parameters are available:

Parameter

Description

environment

Lobster Data Platform / Orchestration environment instance

si

Current user session

root

The current data object

context

The current context with all variables ( e.g. context.getStorage().get("VARNAME") )

em

The current database session

needCurrent

Indicates whether the value must be current

In addition, you can define your own variables, which are also available in the script as variables.

Example

Returns the value 45

images/download/attachments/62851638/image2018-5-18_7_0_14-version-1-modificationdate-1603707415634-api-v2.png

The script can be edited with a highlight editor (1).

Variables (2) can be referenced with the variable name in the script. The value of the variables can be set via value resolvers at runtime.