Bugzilla will be upgraded to version 5.0 on a still to be determined date in the near future. The original upgrade date has been delayed.
Bug 986367 - [RFE] Provide transformer for unit scaling and rate-of-change conversion
[RFE] Provide transformer for unit scaling and rate-of-change conversion
Status: CLOSED ERRATA
Product: Red Hat OpenStack
Classification: Red Hat
Component: openstack-ceilometer (Show other bugs)
4.0
Unspecified Unspecified
high Severity high
: Upstream M2
: 4.0
Assigned To: Eoghan Glynn
Kevin Whitney
https://blueprints.launchpad.net/ceil...
: FutureFeature, OtherQA
Depends On:
Blocks: 973191 RHOS40RFE 987450 1055813
  Show dependency treegraph
 
Reported: 2013-07-19 11:04 EDT by Eoghan Glynn
Modified: 2016-04-26 21:29 EDT (History)
8 users (show)

See Also:
Fixed In Version: openstack-ceilometer-2013.2-0.2.b1.el6ost
Doc Type: Enhancement
Doc Text:
OpenStack Metering now has "transformers", which are a way of calculating a rate-of-change, or doing unit scaling conversions. Transformers are configurable and the values they produce as output can be emitted as derived meters. This enables derived meters to be calculated from the original observations via configurable rules, for example simple scaling such as conversion from °F to °C, or more involved derivation of gauge rates from cumulative totals. OpenStack Metering now provides a generic transformer for such conversions, that is used out-of-the-box for deriving CPU utilization percentage from cumulative CPU time, and may also be re-used for any additional cumulative-to-gauge conversions required via simple configuration.
Story Points: ---
Clone Of:
Environment:
Last Closed: 2013-12-19 19:13:59 EST
Type: Bug
Regression: ---
Mount Type: ---
Documentation: ---
CRM:
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: ---


Attachments (Terms of Use)


External Trackers
Tracker ID Priority Status Summary Last Updated
OpenStack gerrit 35331 None None None Never
OpenStack gerrit 35774 None None None Never
Red Hat Product Errata RHEA-2013:1859 normal SHIPPED_LIVE Red Hat Enterprise Linux OpenStack Platform Enhancement Advisory 2013-12-20 19:01:48 EST

  None (edit)
Description Eoghan Glynn 2013-07-19 11:04:46 EDT
We need the ability to flexibly and efficiently emit derived meters, where the sample values are calculated from a primary meter in the form of a rate-of-change or unit scaling conversion.

This should be achievable via a generic transformer, where the scaling rule is defined in configuration, as opposed to requiring that new pollsters are written on a case-by-case basis.

The canonical example would be the cpu_util meter, which requires that CPU utilization % is calculated on the basis of the first derivative of the cumulative CPU time for an instance.

The existing pollster that currently emits this derived meter should be obsoleted in favour of the generic transformer, appropriately configured:

-
    name: meter_pipeline
    interval: 600
    counters:
        - "*"
    transformers:
    publishers:
        - rpc://
-
    name: cpu_pipeline
    interval: 60
    counters:
        - "cpu"
    transformers:
        - name: "rate_of_change"
          parameters:
              target:
                  name: "cpu_util"
                  unit: "%"
                  type: "gauge"
                  scale: "100.0 / (10**9 * (resource_metadata.cpu_number or 1))"
              replace: False
    publishers:
        - rpc://


Upstream blueprint: https://blueprints.launchpad.net/ceilometer/+spec/transformer-unit
Comment 4 Eoghan Glynn 2013-10-21 11:25:54 EDT
How To Test
===========

0. Install packstack allinone, then spin up an instance in the usual way. 


1. Ensure the old cpu_util pollster is no longer loaded:

  sudo grep cpu_util /usr/lib/python2.?/site-packages/ceilometer-2013*.egg-info/entry_points.txt
  # (no output expected)

whereas the primary cpu pollster is still loaded:

  sudo grep '\<cpu\> /usr/lib/python2.?/site-packages/ceilometer-2013*.egg-info/entry_points.txt


2. Ensure that the cpu and cpu_util meters can be configured with independent cadences:

  sudo sed -i '/^ *name: cpu_pipeline$/ { n ; s/interval: 600$/interval: 60/ }' /etc/ceilometer/pipeline.yaml
  sudo service openstack-ceilometer-compute restart

  sleep 300

  ceilometer sample-list -m cpu
  ceilometer sample-list -m cpu_util

Confirm that the over the most recent time period, the cpu_util is being reported approximately at a ratio of 10:1 in frequency as compared to the cpu meter.
Comment 5 Ami Jeain 2013-10-28 07:50:20 EDT
QANAK'ing due to QE capacity
Comment 11 errata-xmlrpc 2013-12-19 19:13:59 EST
Since the problem described in this bug report should be
resolved in a recent advisory, it has been closed with a
resolution of ERRATA.

For information on the advisory, and where to find the updated
files, follow the link below.

If the solution does not work for you, open a new bug report.

http://rhn.redhat.com/errata/RHEA-2013-1859.html

Note You need to log in before you can comment on or make changes to this bug.