MPS issue job003335

Titleeventcnv's bucket aggregation is broken
Statusclosed
Priorityoptional
Assigned userGareth Rees
OrganizationRavenbrook
DescriptionIf you request that statistics are aggregated into buckets by passing the -b option to eventcnv, the results are bogus.
AnalysisThis code relies on events being processed in order of their eventTime:

    /* Output bucket, if necessary, and update counters */
    if (bucketSize != 0 && eventTime >= bucketLimit) {
      reportBucketResults(bucketLimit-1);
      clearBucket();
      do {
        bucketLimit += bucketSize;
      } while (eventTime >= bucketLimit);
    }

but events may appear out of order in the telemetry file, so this algorithm is bogus. The events need to be sorted before aggregation into buckets (or, alternatively, all events need to be processed before any bucket is output).

For the moment I have dealt with this by not documenting the -b option to eventcnv.
How foundinspection
EvidenceSee analysis.
Observed in1.110.0
Created byGareth Rees
Created on2012-10-21 16:35:36
Last modified byGareth Rees
Last modified on2012-10-23 14:28:22
History2012-10-21 GDR Created.

Fixes

Change Effect Date User Description
180028 closed 2012-10-23 14:28:22 Gareth Rees Remove reporting features from eventcnv, as discussed with RB. Eventcnv was always intended to be a simple tool that just translates events, not a report generator. In particular:
* Remove -e option and associated event specification parsing.
* Remove -b option and bucket statistics.
* Don't intern labels (always print addresses).
* Remove -v option (events are always output).
* If -h or -? is specified, exit after printing help message.
* Help text refer to the "Telemetry" section of reference manual.