Specifications
Application Event Source
indicates this with an icon and the name of the applicable constraint, as shown
in Transactions with Constraints.
Application Event Source
The AR Application Event API allows you to define unique start and end events
that allow the AR agent to explicitly bound a transaction. It supports events
from C and any language supporting COM. It does not support events sent
from remote systems.
API Lifecycle
The API has a well-defined lifecycle of three parts: connection, sending of
events, and disconnection. The lifecycle begins when the application calls one
of the connect functions: ARAppEvent_Connect or IARAppEvent::Connect.
Then the instrumented application calls one of the send event functions
(ARAppEvent_SendEvent or IARAppEvent::SendEvent) one or more times to
notify the AR agent of transaction events. When the application shuts down, it
calls either ARAppEvent_Disconnect or IARAppEvent::Disconnect.
Usage Guidelines
Review the following guidelines before you instrument your application:
Call the Connect function once per application startup because the AR
agent stores state information upon connection.
Call the SendEvent function as many times as necessary but remember
that excessive calls may flood the AR agent. In addition, timing is
disturbed as the number of sent events increase. To prevent the flooding
of the AR agent, send a unique start event and a unique end event per
transaction.
To ensure that AR calculates transaction times accurately, call the
SendEvent function before the application starts the transaction.
Also to ensure that AR calculates transaction times accurately, you should
call the Disconnect function as close to the end of the application
transaction as possible.
Function Descriptions
For supported applications, the Application Event API relies upon three
functions: Connect, SendEvent, and Disconnect. Use the Connect function to
start a session. Use the SendEvent function to send events to the AR agent.
Your application must call the Disconnect function to end a session.
BT Language Reference 217