Elapsed time is the clock time from beginning to end of some unit of work, whether a transaction, a session, or region. Elapsed time is the only clock that is overlapping. All other clocks start and stop when scopes change, transactions nest, locks are held, or system services execute.
Runtime is the clock time associated with the scheduled execution of a unit of work. For example, the session runtime clock stops when a transaction executes since the unit of work scheduled is the transaction. Similarly, when a TIBCO Object Service Broker transaction spawns another transaction, the runtime of the spawning transaction is suspended until the spawned transaction completes.
In the accounting section, runtime consists of executor and system service runtimes. Performance data provide the runtimes for each system service. Normally, the runtime clock and the CPU clock are concurrent.
Lock time is the amount of time some unit of work waits for the availability of scarce Execution Environment resources. Locks managed by the Execution Environment never occur at the system service level.
The relationship between the time fields is best explained when a unit of work is at the highest level of execution (that is, when a transaction is at the highest stream level). At the highest level of execution, the summation of run queue, resume, and lock times equals (or nearly equals) the elapsed time of the work unit.
The difference between runtime and CPU time can be significant and its accountability can be difficult. By definition, runtime is scheduled execution time and CPU time is actual execution time.
Some of the difference between runtime and CPU time can be attributed to the operating system and/or the underlying platform of the Execution Environment. However, you identify large components of wait time in the domain of the Execution Environment by examining the system request section of performance data.
Terminal wait time can be a large element of the difference between runtime and CPU time. Although the terminal wait time is published in the accounting section, it can also be computed by subtracting the CPU time from the runtime of the system service section that monitors all terminal input/output. You can use a similar method to determine the wait time that is associated with Execution Environment and Data Object Broker communications.