Can Event.sendEvent()/Event.routeTo() function be used in Success(Completion) and Failure Listerns to send an event?
book
Article ID: KB0090402
calendar_today
Updated On:
Products
Versions
TIBCO BusinessEvents Enterprise Edition
-
Not Applicable
-
Description
Resolution: Description: ============ Can Event.sendEvent()/Event.routeTo() function be used in Success(Completion) and Failure Listerns to send event?
Resolution: =========== As per the documentation, functions that work within an Run to completion(RTC) cannot be used in listeners. Functions that read, modify, or delete concepts and events, such as Instance.deleteInstance(), cannot be used in listeners. These functions must execute in the context of a run to completion cycle (RTC). They cannot be used in success or failure listeners, which run in a different thread.
The ideal usage for sending events in listeners is the Pattern.IO.toDestination().
Reference: ========== TIBCO BusinessEvents Event Stream Processing Pattern Matcher Developer’s Guide --> Working with the Pattern Matcher Language --> Configuring Success (Completion) and Failure Listeners --> Functions that Work Within an RTC Can’t be Used in Listeners
Issue/Introduction
Can Event.sendEvent()/Event.routeTo() function be used in Success(Completion) and Failure Listerns to send an event?