66
66
| get_driver_vendor_passthru_methods
67
67
| 1.22 - Added configdrive parameter to do_node_deploy.
68
68
| 1.23 - Added do_provisioning_action
69
| 1.24 - Added inspect_hardware method
70
| 1.25 - Added destroy_port
71
| 1.26 - Added continue_node_clean
72
75
# NOTE(rloo): This must be in sync with manager.ConductorManager's.
73
RPC_API_VERSION = '1.23'
76
RPC_API_VERSION = '1.26'
75
78
def __init__(self, topic=None):
76
79
super(ConductorAPI, self).__init__()
323
326
return cctxt.call(context, 'do_provisioning_action',
324
327
node_id=node_id, action=action)
329
def continue_node_clean(self, context, node_id, topic=None):
330
"""Signal to conductor service to start the next cleaning action.
332
:param context: request context.
333
:param node_id: node id or uuid.
334
:param topic: RPC topic. Defaults to self.topic.
335
:raises: NoFreeConductorWorker when there is no free worker to start
337
:raises: InvalidStateRequested if the requested action can not
339
:raises: NodeLocked if node is locked by another conductor.
340
:raises: NodeNotFound if the node no longer appears in the database
342
cctxt = self.client.prepare(topic=topic or self.topic, version='1.26')
343
return cctxt.call(context, 'continue_node_clean',
326
346
def validate_driver_interfaces(self, context, node_id, topic=None):
327
347
"""Validate the `core` and `standardized` interfaces for drivers.
483
503
cctxt = self.client.prepare(topic=topic or self.topic, version='1.17')
484
504
return cctxt.call(context, 'get_supported_boot_devices',
507
def inspect_hardware(self, context, node_id, topic=None):
508
"""Signals the conductor service to perform hardware introspection.
510
:param context: request context.
511
:param node_id: node id or uuid.
512
:param topic: RPC topic. Defaults to self.topic.
513
:raises: NodeLocked if node is locked by another conductor.
514
:raises: HardwareInspectionFailure
515
:raises: NoFreeConductorWorker when there is no free worker to start
517
:raises: UnsupportedDriverExtension if the node's driver doesn't
519
:raises: InvalidStateRequested if 'inspect' is not a valid
520
action to do in the current state.
523
cctxt = self.client.prepare(topic=topic or self.topic, version='1.24')
524
return cctxt.call(context, 'inspect_hardware', node_id=node_id)
526
def destroy_port(self, context, port, topic=None):
529
:param context: request context.
530
:param port: port object
531
:param topic: RPC topic. Defaults to self.topic.
532
:raises: NodeLocked if node is locked by another conductor.
533
:raises: NodeNotFound if the node associated with the port does not
536
cctxt = self.client.prepare(topic=topic or self.topic, version='1.25')
537
return cctxt.call(context, 'destroy_port', port=port)