libvirt: driver class refactoring

Registered by Daniel Berrange

The libvirt driver.py class is growing ever larger and more complicated.
There are circular dependencies between this class and other libvirt
classes. This work aims to split some of the functionality out into
new classes

Blueprint information

Status:
Complete
Approver:
John Garbutt
Priority:
Low
Drafter:
Daniel Berrange
Direction:
Approved
Assignee:
Daniel Berrange
Definition:
Approved
Series goal:
Accepted for kilo
Implementation:
Implemented
Milestone target:
milestone icon 2015.1.0
Started by
John Garbutt
Completed by
John Garbutt

Related branches

Sprints

Whiteboard

Gerrit topic: https://review.openstack.org/#q,topic:libvirt-driver-class-refactor,n,z

Addressed by: https://review.openstack.org/104804
    Libvirt driver class refactoring

Gerrit topic: https://review.openstack.org/#q,topic:bp/libvirt-driver-class-refactor,n,z

Addressed by: https://review.openstack.org/104930
    libvirt: introduce new 'Host' class to manage the connection

Its Feature Proposal Freeze now, so lets call this partially complete for juno. No more juno patches please. --johnthetubaguy 22nd August 2014

Sorry, this does not have enough positive reviews to make it for juno-3, please resubmit for kilo. For more information, please contact me (johnthetubaguy) via IRC or email. --johnthetubaguy 2nd September 2014

This doesn't need a spec for kilo, approved. --johnthetubaguy

Addressed by: https://review.openstack.org/140099
    virt: delete unused 'interface_stats' method

Addressed by: https://review.openstack.org/140711
    virt: Convert more tests to use instance objects

Addressed by: https://review.openstack.org/140712
    libvirt: Convert more tests to use instance objects

Addressed by: https://review.openstack.org/140713
    virt: pass instance object to block_stats & get_instance_disk_info

Addressed by: https://review.openstack.org/140714
    libvirt: introduce a fixture for mocking out libvirt connections

Addressed by: https://review.openstack.org/140715
    libvirt: convert test_host.py to use FakeLibvirtFixture

Addressed by: https://review.openstack.org/140716
    libvirt: sanitize use of mocking in test_host.py

Addressed by: https://review.openstack.org/140717
    libvirt: remove unused get_connection parameter from VIF driver

Addressed by: https://review.openstack.org/140718
    libvirt: pass Host object into firewall class

Addressed by: https://review.openstack.org/140719
    libvirt: remove pointless _get_host_uuid method

Addressed by: https://review.openstack.org/140720
    libvirt: introduce new helper for getting libvirt domain

Addressed by: https://review.openstack.org/140721
    libvirt: move domain lookup helpers into Host class

Addressed by: https://review.openstack.org/140722
    libvirt: move domain list helpers into Host class

Addressed by: https://review.openstack.org/140723
    libvirt: move capabilities helper into host.py

Addressed by: https://review.openstack.org/140724
    libvirt: remove/revert pointless logic for getVersion call

Addressed by: https://review.openstack.org/140725
    libvirt: move _get_hypervisor_* functions to Host class

Addressed by: https://review.openstack.org/140726
    libvirt: convert LibvirtConnTestCase to use fakelibvirt fixture

Addressed by: https://review.openstack.org/140727
    libvirt: rename self.libvirtconnection in LibvirtDriverTestCase

Addressed by: https://review.openstack.org/140728
    libvirt: rename self.conn in LibvirtVolume{Snapshot||Usage}TestCase

Addressed by: https://review.openstack.org/140729
    libvirt: rename conn variable in LibvirtConnTestCase

Moving to kilo-2, as its not been moved into the NeedsCodeReview state, it is assumed that not all patches are yet up for review. --johnthetubaguy 16th December 2014

Gerrit topic: https://review.openstack.org/#q,topic:libvirt-driver-refactor-3,n,z

Gerrit topic: https://review.openstack.org/#q,topic:libvirt-driver-refactor-4,n,z

All patches merged, now reached feature proposal freeze, marking as complete. --johnthetubaguy 26th Jan 2015

(?)

Work Items

This blueprint contains Public information 
Everyone can see this information.