Officially deprecate agent passthru classes and API

We've introduced the new set of API endpoints for lookup and heartbeat
which all drivers should implement now and all ramdisk should use.

IPA switched to the new API in the Newton release. The deprecated passthru
endpoints and classes will be removed in the Ocata release.

Change-Id: If0d189ecdd4b84d1dbac274e6dec200e13dfe37c
Depends-On: I7160c99ca63585fc333482fa578fdf5e0962b2b6
Closes-Bug: #1570841
This commit is contained in:
Dmitry Tantsur 2016-07-01 14:59:59 +02:00 committed by Jim Rollenhagen
parent 8bdd538c0c
commit 2f84daaa6f
4 changed files with 22 additions and 1 deletions

View File

@ -565,6 +565,9 @@ class AgentVendorInterface(agent_base_vendor.BaseAgentVendor,
"""Implementation of agent vendor interface.
Contains old lookup and heartbeat endpoints currently pending deprecation.
WARNING: This class is deprecated and will be removed in the Ocata release.
Drivers should stop relying on it.
"""

View File

@ -655,6 +655,8 @@ class AgentDeployMixin(object):
node.uuid)
# TODO(dtantsur): deprecate and remove it as soon as we stop using it ourselves
# in the Ocata release.
class BaseAgentVendor(AgentDeployMixin, base.VendorInterface):
def __init__(self):
@ -766,6 +768,10 @@ class BaseAgentVendor(AgentDeployMixin, base.VendorInterface):
:raises: NotFound if no matching node is found.
:raises: InvalidParameterValue with unknown payload version
"""
LOG.warning(
_LW('Agent lookup vendor passthru is deprecated and will be '
'removed in the Ocata release; please update your '
'ironic-python-agent image to the Newton version'))
LOG.debug('Agent lookup using data %s', kwargs)
uuid = kwargs.get('node_uuid')
if uuid:

View File

@ -581,4 +581,10 @@ class ISCSIDeploy(AgentDeployMixin, base.DeployInterface):
class VendorPassthru(AgentDeployMixin, agent_base_vendor.BaseAgentVendor):
"""Interface to mix IPMI and PXE vendor-specific interfaces."""
"""Interface to mix IPMI and PXE vendor-specific interfaces.
Contains old lookup and heartbeat endpoints currently pending deprecation.
WARNING: This class is deprecated and will be removed in the Ocata release.
Drivers should stop relying on it.
"""

View File

@ -0,0 +1,6 @@
---
deprecations:
- Agent vendor passthru is deprecated and will be removed in Ocata release.
Operators should update their IPA image to the Newton version to use
the new replacement API. Driver developers should stop using the agent
vendor passthru.