Instrumentation
MyARM provides support for instrumentation of C/C++ and Java applications. The following tools and frameworks are shipping with the MyARM distribution.
- armtime
- Command line tool which executes and measures another program given at command line arguments.
- QArm Qt 4 framework
- The Qt 4 ARM framework will easliy integrate into existing Qt applications and will provide a simple measurement interface.
Currently instrumentation of the following programs are underway.
- Web-Server chain
- Based on the Apache web-server and MySQL or SQlite database engine we will provide end-to-end measurements in web-server area.
Correlator issues
ARM provides an unique and powerful correlation of transactions within distributed systems. The so-called correlator is used to correlate two transactions with a parent-child relationship. A correlator needs to be passed from ony system to another for example from a web-client (browser) to a web-server (httpd). Therefore the correlator must be converted into an ASCII representation because these programs communicate with each other using an ASCII protocol named HTTP.
MyARM provides different string representations of a correlator. For compatibility reasons with the first mod_arm4 Apache HTTP Server modul, a correlator string without any type information is treated as a hexadecimal encoded string.
To support more encodings MyARM introduces a string prefix followed by a colon to specify the type of encoding. Currently the following encoding types are supported:
- b64
- the correlator string following the colon is base 64 encoded.
- hex
- the correlator string following the colon is hexadecimal encoded.
Using an environment variable
If an correlator is passed using an environment variable between
two components the environment variable called
ARM_CORRELATOR is used. This technique can be used to
pass a correlator between:
- Two programs
- The first program sets the
ARM_CORRELATORenvironment variable and starts a second program which reads the environment variable to use its contents as its parent correlator. See armtime program. - Progam and a library
- If a program uses a library which does not support ARM by its interface the environment variable technique can be used to pass a parent correlator to the ARM instrumentation within a library.
For example the following command will print out the MyARM generated correlator as a hexadecimal encoded string:
armtime echo "ARM_CORRELATOR=$ARM_CORRELATOR"
will produce the following output:
ARM_CORRELATOR=0019640001000002012127097952961ab7519b8fa97486216c