3.3.4.4.1.1 A Basic Implementation
static TM32I _TMDLLENTRY print_app(perf_mon_1 * ip,FBFR32 **buf, MONITORCTL * monctl, TM32U flags)
{
Fprint32(*buf);
return(0);
}
Understanding Current Monitoring Points
Call path monitoring is the most comprehensive Oracle Tuxedo application interceptor. It provides a variety of metrics for recording and analysis.
- Determine the monitoring stage
The monitoring stage itself is a metric with the FML32 field name
TA_MONSTAGE. The following table listsTA_MONSTAGEvalues.
Table 3-7 TA_MONSTAGE Values
| Value | Description |
|---|---|
STMO |
A new call path monitoring is initiated. This is the first record for the current monitored call path. |
ME2Q |
Before a message is sent to the IPC. It could be a request message or reply message. For the monitoring “initiator”, “STMO” replaces “ME2Q” stage since they are at the same point. |
Q2ME |
Before a message is received from the IPC. It could be a request or reply message |
ME2NET |
Before a message sent to the network. It only applies to GWTDOMAIN. It could be a request message or reply message.
|
NET2ME |
After a message is received from the network. It only applies to GWTDOMAIN. It could be a request message or reply message.
|
The following listing displays a judge monitoring stage example.
Judge Monitoring Stage
{
char *stage;
FLDLEN32 len;
stage = Ffind32(*obuf, TA_MONSTAGE,0,&len);
if (stage != NULL ) {
if (strcmp(stage,”STMO”) == 0 ) {
/* ... */
}else if (strcmp(stage,”Q2ME” == 0 ) {
/* ... */
/* other processment */
}
}For “STRING” field type, we recommend to use “Ffind32” routine to get a more fast process.
- Determine the message type
For an application message transmitted in the Oracle Tuxedo system, it has two choice, request message or reply message. The field
TA_MONMSGTYPEindicates the message type.The following table lists the
TA_MONMSGTYPEvalues.
Table 3-8 TA_MONMSGTYPE Values
| Value | Description |
|---|---|
ARQ |
Request Message |
ARP |
Reply Message |
- Determine current process location
The monitoring points always are located in processes of Oracle Tuxedo applications. So understand current process is important. Oracle TSAM Plus framework uses the fields
TA_DOMAINID,TA_PID,TA_LMID,TA_MONPROCNAME,TA_GROUPNAMEandTA_SRVID(as defined in Table below) to tell the process location.
Table 3-9 Current Process Location Fields
| Format | Description |
|---|---|
TA_DOMAINID
|
The domain identifier. Its format is: domainid: mastername:ipckey
|
TA_PID |
Process ID |
TA_LMID |
Logic machine ID |
TA_MONPROCNAME |
Process name. |
TA_GROUPNAME |
Oracle Tuxedo server group name |
TA_SRVID |
Oracle Tuxedo server ID. |
Note:
Not all metrics available for certain processes. For example, for client processes,TA_SRVID is not available.
Parent topic: Call Path Monitoring Plug-in Routine