The purpose of the statistics server is to collect statistical information from all servers in the system. The statistics server stores the data, in memory, saving the data at a specified interval of time.
The statistics system operates with two types of statistics types: timed information and timeless information. Timed information is a value recorded over time (ex. Response time, workload etc.), . Timeless information, is a value but where time does not have any meaning (ex. Internal execution time, counting etc.).
Timed statistical elements are stored internally, in arrays where each array element (called timeslot), represents one or more statistical data elements. Each timeslot is updated when new data is “added”.
Time based statistics use an expression called time-slot. A time-slot is the a statistical unit which can contain a series of measurements on which average, minimum and maximum values and be calculated. A measurement period can therefore contain many time-slots.
If, for example, in one hour there are 3600 time slots defined, then a time slot corresponds to one second. That means that all measurements within one second are stored in the same time-slot.
There are 4 levels of detail within the time based statistics:
The above values are the default time slots and intervals – they can be changed by modifying the appropriate configuration properties for the statistics server. These properties are:
resolution.secondinterval, resolution.secondcount, resolution.minuteinterval, resolution.minutecount,
resolution.hoursinterval, resolution.hourscount, resolution.daysinterval, resolution.dayscount
E.g. changing resolution.secondinterval to 1 and resolution.secondcount to 3600 will change the resolution to 1 second measurements with a history of 1 hour, but at the cost of increasing the memory usage in the statistics server significantly.
A way of minimizing the memory usage could be to set the resolution.secondcount to 0, and increasing resolution.minuteinterval to 5 while setting resolution.minutecount to 288. This will lower the resolution of the available statistics, but also the memory usage.
If you need the statistics to be kept longer that one year, simply change resolution.dayscount to the number of days you want the statistics kept, e.g. 1095 for 3 years.
A statistical event, will be stored I each of the 4 levels of detail in the time-slot which corresponds to the level of detail. This means that if two events occur with a 5 second interval, the first event will be stored in one time slot and the second event will be stored in another time slot at level of detail 1 above, while the two events together will be stored in the same time slot in item 2, 3 and 4 level of detail above.
When an event is stored in a time slot an update is done of the actual time slot, so that a time slot and its summaries are updated and stored real time.
A time slot contains the following attributes:
From a time slot the following can be calculated:
The calculation of fractiles assumes that measurements follow a normal distribution. If the measurements in certain cases do not follow a normal distribution, then the estimate will not reflect the lower and upper fractiles. In this case these calculations must be ignored.