The following three classes of objects are specified in the ARM API:
There are no preset definitions for ARM objects within an application. The application instrumentor decides how to model the business objects into these three classes.
The ARM API uses numeric identifiers or IDs to uniquely identify the ARM objects that are input and output from the API calls. The three different classes of IDs that correspond to the three ARM classes are
IDs are numeric, signed integers. The Measurement Agent usually assigns IDs. The scheme for assigning IDs varies from one vendor's agent to another, but, at a minimum, uniqueness within a single session is guaranteed. Some Measurement Agents allow you to pre-assign IDs.
The following six calls are used in the ARM API:
The ARM API calls are implemented in SAS software with SAS macros and provide a way to measure the performance of SAS applications as they are running. For each call in the ARM API standard, there exists a corresponding SAS macro. The following table shows the relationship between the ARM API calls and SAS macros:
ARM API call |
SAS Macro |
arm_init | %arminit |
arm_getid | %armgtid |
arm_start | %armstrt |
arm_update | %armupdt |
arm_stop | %armstop |
arm_end | %armend |
The macros provide the most efficient method for invoking the ARM API calls, and it is recommended that you use these macros. The primary advantage of using the macros is that they manage the returned IDs automatically.
The ARM macros use variables to pass IDs and other information. Because the macros must function within the same DATA step as well as across DATA steps, variables that are used by the macros might take the form of DATA step variables or of macro variables. As a general rule, the macros store the returned IDs as
In the DATA step environment, but not the SCL environment, DROP statements are generated for variables so that they are not included in any output datasets.
Some important information about the ARM macros follows:
The following SAS and macro variables are used internally by the ARM macros:
Variable |
Description |
Set by |
Used as input by |
_armapid | application ID | %arminit | %armgtid %armend |
_armtxid | transaction class ID | %armgtid | %armstart |
_armshdl | start handle | %armstrt |
%armupdt, %armstop |
_armrc | error status |
%armupdt, %armstop, %armend |
none |
_armglvl | global level indicator | calling program | all |
_armtlvl | target level indicator | calling program | all |
_armexec | global enablement | calling program | all |
_armacro | open code enablement | calling program | all |
_armscl | SCL code enablement | calling program | all |
As long as values for these variables are not changed outside of the ARM macros, then the macros will function in a self-contained manner and not affect any surrounding code.
Parameters for the ARM macros are very similar to the parameters in the ARM API calls. However, the macros support the following additional parameters to control: