Timer sensor
Overview
The timer sensor types measure the execution time of methods within the monitored application. inspectIT provides different multiple realizations of the timer sensors.Â
From inspectIT version 1.6.8 there is only a single realization of the timer sensor.
Configuration
Configuration basics
Using the UI configuration interface no configuration is required at all as method sensor types are activated automatically if a profile defines such sensor assignment.Â
Generic timer factory
Apart from the "Average Timer", inspectIT provides a "Timer" sensor that was created to easily integrate different realizations of the same timer behaviour. Each implementation collects and/or stores the values in a different way, thus affecting system resources in a different manner. Switching between internal implementations is completely transparent to the user of inspectIT.
Example: The default implementation of the "timer" listens to the callbacks of the method hooks and calculates the time spent within the method. This information is directly aggregated within the sensor for all calls within this data collection interval. Thus data aggregation is done within the JVM of the application to be monitored. Another implementation of the "timer" does not calculate the average time within the sensor but sends raw data to the CMR. In this case the CMR will deal with aggregation of data. The information the user will see do not differ - in fact the user will not even be aware about which implementation will be used. It is completely transparent. Approach (a) will most likely use more CPU time than approach (b), but approach (b) will definitely sent much more data over the network.
Available Timer Realizations
The following modes are available for the timer sensor.
Timer mode | Description | Network | CPU |
---|---|---|---|
aggregate | aggregates the data before sending to minimize the network load, but will affect the application JVM | ||
optimized | reduces the memory usage as it calculates the results immediately when new measurements arrive | ||
raw | timer measurements are collected, but not aggregated. All data is sent to the CMR. |
Configuration
Configuration basics
At the moment the UI configuration interface does not provide configuration option for selecting the timer realization.
Comparison to the Average Timer
The Average Timer sensor type is basically the same as the Timer sensor type with a difference in the processing of the recorded data. The Timer sensor type is using a factory internally to select the storage mechanism based on the definition in the configuration. The Average Timer doesn't need this configuration and the aggregated mode in the Timer sensor type is the same as the one used in the Average Timer. Thus the difference is only that the additional abstraction is removed and the processing and storing of values should be a little bit faster.
Other options
String length
from version 1.3
This sensor enables the limitations of the string values collected. The timer sensor concretely can limit the maximum size of the strings collected as context parameters.
Configuration basics
The string length configuration for all sensors is available in the Environment configuration. You can read more about string length limitations Environment configuration page.