From e16287766dbf9497b0a9ecae852ebcb26308f980 Mon Sep 17 00:00:00 2001 From: Doug Hellmann Date: Mon, 25 Jun 2012 16:52:08 -0400 Subject: [PATCH] Emit meter event for instance "exists" bug 1005941 As we check the CPU utilization for an instance also emit a meter message indicating that the instance still exists. Change-Id: I7a592efc750c6e0a9a24394e05bd2d75da3377b6 --- ceilometer/compute/libvirt.py | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/ceilometer/compute/libvirt.py b/ceilometer/compute/libvirt.py index ac1693c11..f29717bc7 100644 --- a/ceilometer/compute/libvirt.py +++ b/ceilometer/compute/libvirt.py @@ -122,6 +122,11 @@ class CPUPollster(plugin.PollsterBase): type='cumulative', volume=cpu_info['cpu_time'], ) + yield make_counter_from_instance(instance, + name='instance', + type='delta', + volume=1, + ) except Exception as err: self.LOG.error('could not get CPU time for %s: %s', instance.uuid, err)