compute pollster uses internal nova libvirt connection API
Bug #1065945 reported by
Eoghan Glynn
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.
Changed in ceilometer: | |
status: | New → Fix Committed |
importance: | Undecided → High |
Changed in ceilometer: | |
milestone: | none → grizzly-2 |
status: | Fix Committed → Fix Released |
Changed in ceilometer: | |
milestone: | grizzly-2 → 2013.1 |
To post a comment you must log in.
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 connection( ): connection. get_connection( read_only= True) lookupByName( instance) connection( ) connection( ) lookupByName( instance. name) connection( ) lookupByName( instance. name)
def get_libvirt_
return nova.virt.
domain = conn._conn.
conn = get_libvirt_
conn = get_libvirt_
domain = conn._conn.
conn = get_libvirt_
domain = conn._conn.
$ grep domain ceilometer/ compute/ libvirt. py lookupByName( instance) g(domain. XMLDesc( 0)) lookupByName( instance. name) g(domain. XMLDesc( 0)) lookupByName( instance. name)
domain. interfaceStats( vnic['name' ])
domain = conn._conn.
tree = etree.fromstrin
domain = conn._conn.
tree = etree.fromstrin
domain = conn._conn.