aodh/ceilometer
Eoghan Glynn cdc49d6c75 Selectable aggregation functions for statistics
Addresses: BP selectable-aggregates

Previously, the statistics API always computed and returned a
standard set of aggregate functions.

Now, individual aggregation functions can be selected and even
parameterized via syntax of form:

   /v2/meters/<meter_name>/statistics?aggregate.func=<name>&aggregate.param=<value>

For example in order to calculate the average CPU util only:

  GET /v2/meters/cpu_util/statistics?aggregate.func=avg

  HTTP/1.0 200 OK
  [{"aggregate": {"avg": 0.6858829535841072},
    "avg": 0.6858829535841072,
    "duration_start": "2014-01-30T11:13:23",
    "duration_end": "2014-01-31T16:07:13",
    "duration": 104030.0,
    "period": 0,
    "period_start": "2014-01-30T11:13:23",
    "period_end": "2014-01-31T16:07:13",
    "groupby": null,
    "unit": "%"}]

In the current patch, selectable aggregates are provided by the
sqlalchemy driver only, with support in the mongodb driver to
follow in a subsequent patch.

Change-Id: I6cc095ba5ae16dea3f6b404e72a070ab9ac49c9a
2014-03-03 21:23:22 +00:00
..
2014-02-28 23:14:52 +00:00
2014-02-08 06:46:32 +01:00
2014-02-19 01:13:52 +00:00
2014-02-08 06:46:32 +01:00
2014-02-08 06:46:32 +01:00
2014-02-08 06:46:32 +01:00
2014-02-08 06:46:32 +01:00
2014-02-14 22:31:32 +08:00
2014-02-25 14:15:55 -05:00
2014-02-08 06:46:32 +01:00
2014-03-03 19:52:16 +00:00