Bases: ironic.objects.base.IronicObject, oslo_versionedobjects.base.VersionedObjectDictCompat
Create a Node record in the DB.
Column-wise updates will be made based on the result of self.what_changed(). If target_power_state is provided, it will be checked against the in-database copy of the node before updates are made.
Parameters: | context – Security context. NOTE: This should only be used internally by the indirection_api. Unfortunately, RPC requires context as the first argument, even though we don’t use it. A context should be set when instantiating the object, e.g.: Node(context) |
---|---|
Raises: | InvalidParameterValue if some property values are invalid. |
Delete the Node from the DB.
Parameters: | context – Security context. NOTE: This should only be used internally by the indirection_api. Unfortunately, RPC requires context as the first argument, even though we don’t use it. A context should be set when instantiating the object, e.g.: Node(context) |
---|
Find a node based on its id or uuid and return a Node object.
Parameters: | node_id – the id or uuid of a node. |
---|---|
Returns: | a Node object. |
Find a node based on its integer id and return a Node object.
Parameters: | node_id – the id of a node. |
---|---|
Returns: | a Node object. |
Find a node based on the instance uuid and return a Node object.
Parameters: | uuid – the uuid of the instance. |
---|---|
Returns: | a Node object. |
Find a node based on name and return a Node object.
Parameters: | name – the logical name of a node. |
---|---|
Returns: | a Node object. |
Get a node by associated port addresses.
Parameters: |
|
---|---|
Raises: | NodeNotFound if the node is not found. |
Returns: | a Node object. |
Find a node based on uuid and return a Node object.
Parameters: | uuid – the uuid of a node. |
---|---|
Returns: | a Node object. |
Return a list of Node objects.
Parameters: |
|
---|---|
Returns: | a list of Node object. |
Refresh the object by re-fetching from the DB.
Parameters: | context – Security context. NOTE: This should only be used internally by the indirection_api. Unfortunately, RPC requires context as the first argument, even though we don’t use it. A context should be set when instantiating the object, e.g.: Node(context) |
---|
Release the reservation on a node.
Parameters: |
|
---|---|
Raises: | NodeNotFound if the node is not found. |
Get and reserve a node.
To prevent other ManagerServices from manipulating the given Node while a Task is performed, mark it reserved by this host.
Parameters: |
|
---|---|
Raises: | NodeNotFound if the node is not found. |
Returns: | a Node object. |
Save updates to this Node.
Column-wise updates will be made based on the result of self.what_changed(). If target_power_state is provided, it will be checked against the in-database copy of the node before updates are made.
Parameters: | context – Security context. NOTE: This should only be used internally by the indirection_api. Unfortunately, RPC requires context as the first argument, even though we don’t use it. A context should be set when instantiating the object, e.g.: Node(context) |
---|---|
Raises: | InvalidParameterValue if some property values are invalid. |