Tips & Tricks - Start processes

This article shows different ways to start processes, e.g. as a follow-up order of data transfers or tasks, or by JavaScript.

Start the process via a task

To execute a process as a subsequent job, the process requires a Generic event handler. In the properties dialog of the event handler select the class "de.uplanet.lucy.server.workflow.eventhandler.UserWorkflowEventHandler" on the "Generic event handler" tab. The automatically created parameter "eventGuid" has a GUID as its value. Copy the GUID to the clipboard or save it somewhere else (e.g. a text editor) so that it can be used easily later on. Additional process elements can be connected to the Generic event handler as usual.

When using a generic event handler there is no direct relationship to a data group. Thus you have no dynamic data records available, for example.

Using the GUID defined in the generic event handler, the process can now be started from the task scheduler, which you can find in the "Tools" module.

Select any task from the list. Select "Edit schedule" from the context menu to open the "Subsequent jobs" tab. Enter the eventGuid from the Generic event handler in the "Process event GUID" field. This means the process will start as soon as the task has been performed.

Start the process via a data transfer

Processes can be triggered after a Data transfer in the "Integration" module. Open the properties dialog of an existing data transfer and switch to the "Subsequent jobs" tab. Enter the eventGuid from the Generic event handler in the "Process event GUID" field. This means the process will start as soon as the data transfer has been performed.

Start the process via a JavaScript

A process can also be started as follows via JavaScript:

function prozess_start()
{
	triggerUserWorkflowEvent("GUID");
}

The function "triggerUserWorkflowEvent()" triggers the process. This function requires the eventGuid of the corresponding generic event handler.

You can identify the GUID by selecting the generic event handler in the process and then pressing F4.