The watcher.decision_engine.model.mapping Module

class watcher.decision_engine.model.mapping.Mapping(model)[source]

Bases: object

get_mapping()[source]
get_node_by_instance_uuid(instance_uuid)[source]

Getting host information from the guest instance

Parameters:instance – the uuid of the instance
Returns:node
get_node_from_instance(instance)[source]
get_node_instances(node)[source]

Get the list of instances running on the node

Parameters:node
Returns:
get_node_instances_by_uuid(node_uuid)[source]
map(node, instance)[source]

Select the node where the instance is launched

Parameters:
  • node – the node
  • instance – the virtual machine or instance
unmap(node, instance)[source]

Remove the instance from the node

Parameters:
  • node – the node
  • instance – the virtual machine or instance
unmap_by_uuid(node_uuid, instance_uuid)[source]

Remove the instance (by id) from the node (by id)

:rtype : object