From d1c47cbf72a77b2b32c6bf5ac46acd57455200a8 Mon Sep 17 00:00:00 2001 From: Jim Rollenhagen Date: Tue, 9 Aug 2016 12:01:19 -0400 Subject: [PATCH] Deprecate ClusteredComputeManager As of nova's Newton release, the ironic virt driver supports multiple compute hosts without using the hack we call ClusteredComputeManager. Deprecate it so we can remove it in Ocata. Change-Id: I9c44429666734e5bdbe60b3ff8bba787ff99a6d1 --- ironic/nova/compute/manager.py | 19 ++++++++++++++++++- ...ered-compute-manager-3dd68557446bcc5c.yaml | 12 ++++++++++++ 2 files changed, 30 insertions(+), 1 deletion(-) create mode 100644 releasenotes/notes/deprecate-clustered-compute-manager-3dd68557446bcc5c.yaml diff --git a/ironic/nova/compute/manager.py b/ironic/nova/compute/manager.py index c2bf47a3fe..59782d7bdb 100644 --- a/ironic/nova/compute/manager.py +++ b/ironic/nova/compute/manager.py @@ -23,16 +23,33 @@ work. The goal here is to generalise the areas where n-c talking to a clustered hypervisor has issues, and long term fold them into the main ComputeManager. """ +from oslo_concurrency import lockutils +from oslo_log import log as logging + from nova.compute import manager import nova.context -from oslo_concurrency import lockutils +from nova.i18n import _LW +LOG = logging.getLogger(__name__) + CCM_SEMAPHORE = 'clustered_compute_manager' +# TODO(jroll) delete this in Ocata class ClusteredComputeManager(manager.ComputeManager): + def __init__(self, *args, **kwargs): + LOG.warning(_LW('ClusteredComputeManager is deprecated. As of the ' + 'Newton release of Nova, the ironic ' + 'virt driver directly supports using multiple ' + 'compute hosts without ClusteredComputeManager. ' + 'Users should unset the `compute_manager` ' + 'configuration option to use Nova\'s default ' + 'instead. ClusteredComputeManager will be removed ' + 'during the Ocata cycle.')) + super(ClusteredComputeManager, self).__init__(*args, **kwargs) + def init_host(self): """Initialization for a clustered compute service.""" self.driver.init_host(host=self.host) diff --git a/releasenotes/notes/deprecate-clustered-compute-manager-3dd68557446bcc5c.yaml b/releasenotes/notes/deprecate-clustered-compute-manager-3dd68557446bcc5c.yaml new file mode 100644 index 0000000000..539f917602 --- /dev/null +++ b/releasenotes/notes/deprecate-clustered-compute-manager-3dd68557446bcc5c.yaml @@ -0,0 +1,12 @@ +--- +deprecations: + - | + In Nova commit 6047d790a32ef5a65d4d6b029f673ce53c3d4141, + functionality is added to the ironic virt + driver to support multiple compute hosts without using the hack + we call ClusteredComputeManager. + + We anticipate this being included in the Newton release of Nova. + In advance of that, we are marking this unsupported component + as deprecated, and plan to remove it before the end of the Ocata + development cycle.