compute pollster uses internal nova libvirt connection API

Bug #1065945 reported by Eoghan Glynn
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
Ceilometer
Fix Released
High
Unassigned

Bug Description

The compute pollster depends on the nova libvirt connection '_conn' atribute, which looks like a potentially problematic usage of an internal nova API which may be open to change without notice.

This usage should be replaced with an agreed stable API.

Revision history for this message
Doug Hellmann (doug-hellmann) wrote :

It looks like what we need is a way to get the domain data from the connection so we can pull out values from the XML. Do we want the API to give us the raw data, or should we add an API to get the stats we want so other hypervisors can implement those new calls and integrate with us more easily?

$ grep _conn ceilometer/compute/libvirt.py
def get_libvirt_connection():
        return nova.virt.connection.get_connection(read_only=True)
        domain = conn._conn.lookupByName(instance)
            conn = get_libvirt_connection()
        conn = get_libvirt_connection()
        domain = conn._conn.lookupByName(instance.name)
        conn = get_libvirt_connection()
            domain = conn._conn.lookupByName(instance.name)

$ grep domain ceilometer/compute/libvirt.py
        domain = conn._conn.lookupByName(instance)
        tree = etree.fromstring(domain.XMLDesc(0))
        domain = conn._conn.lookupByName(instance.name)
        tree = etree.fromstring(domain.XMLDesc(0))
            domain = conn._conn.lookupByName(instance.name)
                    domain.interfaceStats(vnic['name'])

Revision history for this message
Julien Danjou (jdanjou) wrote :

We should add an API to get the stats we want so other hypervisors can implement those new calls and integrate with us more easily.

Nick Barcet (nijaba)
Changed in ceilometer:
status: New → Fix Committed
importance: Undecided → High
Thierry Carrez (ttx)
Changed in ceilometer:
milestone: none → grizzly-2
status: Fix Committed → Fix Released
Thierry Carrez (ttx)
Changed in ceilometer:
milestone: grizzly-2 → 2013.1
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Related blueprints

Remote bug watches

Bug watches keep track of this bug in other bug trackers.