Skip Navigation
Expand
There are two types of execution for Object Event Handlers
Answer ID 6604   |   Last Review Date 10/19/2018

What is the difference between asynchronous and synchronous execution of Object Event Handlers in the custom process?

Environment:

Process Designer, Custom Process Model (CPM) / Service Process Model (SPM)
November 2013 version and newer

Resolution:

Synchronous execution of an Object Event Handler has a strict time limit of 5 seconds. It is intended for processes that are executed without interruption from start to finish. Synchronous execution of an Object Event handler requires the code executing it to wait until the handler is completed to continue execution.

Asynchronous execution of an Object Event Handler has a time limit of 157 seconds of processing time, execution is controlled by a queuing system. If there is a failure to execute the first time, the process can be repeated up to four times. Retry intervals increase over time (from 90,450, 3150, and 34,650 seconds respectively). The goal is to ensure that the resources needed for execution are available.

Asynchronous execution is intended for event handlers that do not need to execute immediately. An example that may use asynchronous execution could be an integration that updates contact information in an external database when a contact is created in Oracle RightNow CX. Asynchronous execution is anticipated for Object Event Handlers that have been created to replace External Events.

To set the event handler to execute asynchronously, select the Execute Asynchronously check box and/or name the handler with the async keyword. This needs to be done before a CPM customization is first saved, since this aspect of the configuration is non-editable for existing CPM customizations. For details on how to delete a CPM customization see

Answer ID 7883: Delete Custom Process Model Script (CPM)

For more information, refer to the following:

Answer ID 9453: Two second guideline for synchronous CPMs

Answer ID 6907: Limitations of synchronous object event handlers when attached to the answer object.

 

Available Languages for this Answer:

Notify Me
The page will refresh upon submission. Any pending input will be lost.