Documentation Orchestrator¶
-
class
motey.orchestrator.inter_node_orchestrator.
InterNodeOrchestrator
(logger, valmanager, service_repository, labeling_repository, node_repository, communication_manager)[source]¶ This class orchestrates services. It will start and stop virtual instances of images defined in the service. It also can communicate with other nodes to start instances there if the requirements does not fit with the possibilities of the current node.
-
compare_capabilities
(needed_capabilities, node_capabilities)[source]¶ Compares two dicts with capabilities.
Parameters: Returns: True if all capabilities are fulfilled, otherwiese False
-
deploy_service
(service)[source]¶ Deploy all images of a service to the related nodes.
Parameters: service (motey.models.service.Service) – the service which should be deployed
-
find_node
(image)[source]¶ Try to find a node in the cluster which can be used to deploy the given image.
Parameters: image (motey.models.image.Image) – the image to be used Returns: the IP of the node to be used or None if it does not found a node which fulfill all capabilities
-
get_service_status
(service)[source]¶ Retruns the service status.
Parameters: service (motey.models.service.Service) – the service which should be used Returns: the status of the service
-
handle_blueprint
(blueprint_data)[source]¶ Try to load the YAML data from the given blueprint data and validates them by using the
motey.models.schemas.blueprint_yaml_schema
. If the data is valid, they will be transformed into a services model and handed over to theVALManager
.Parameters: blueprint_data – data in YAML format which matches the motey.models.schemas.blueprint_yaml_schema
-
instantiate_service
(service)[source]¶ Instantiate a service.
Parameters: service (motey.models.service.Service) – the service to be used.
-