Events created using Event.createEvent() and failed to be sent were not returned in error handler rulefunction in TIBCO BusinessEvents.

Events created using Event.createEvent() and failed to be sent were not returned in error handler rulefunction in TIBCO BusinessEvents.

book

Article ID: KB0090014

calendar_today

Updated On:

Products Versions
TIBCO BusinessEvents Enterprise Edition -
Not Applicable -

Description

Resolution:
Description:
============
In rule, an event was created using Event.creatEvent(), and then sent out using Event.sendEvent(). An Error Handler rulefunction was correctly configured (be.engine.txn.error.function is set, and Agent.&ltagent_name>.enableParallelOps is set to ture). When the sendEvent failed in Post RTC this newly created event was not returned in Error Handler function.

Environment:
==========
TIBCO BusinessEvents - 4.0.2 hf1, 5.0.1 hf4, 5.1.x
OS - all

Cause:
======
The Error Handler only returns those objects to be written to Cache such as"\:

1). Cache only Concepts
2). Cache only incoming Events

Resolution:
=========
To track  events failed to be sent out use the extended catalog function, Event.Ext.sendEvent():

++++++++++++++++++++
SimpleEvent sendEventExt(SimpleEvent evt, boolean forceImmediate) throws Exception
Parameters:
#1 evt SimpleEvent  - An SimpleEvent to send.
#2 forceImmediate boolean - If true, the event will be immediately passed off to the default destination to be sent.

Returns: SimpleEvent The same SimpleEvent. Null if there is an error, of the argument was null.

Cautions: This method will fail if the SimpleEvent has not been configured with any default channel and destination information. This method may throw an exception
+++++++++++++++++++++

Note, with BE 4.x, 5.0.x, you need to enable the following property in studio.tra file to enable extended catalog functions in Studio:
+++++++++++++++++++++
TIBCO.BE.function.catalog.Event.ext=true
+++++++++++++++++++++

Issue/Introduction

Events created using Event.createEvent() and failed to be sent were not returned in error handler rulefunction in TIBCO BusinessEvents.