Search in sources :

Example 1 with DeprecatedNodeTask

use of alien4cloud.topology.task.DeprecatedNodeTask in project alien4cloud by alien4cloud.

the class DeprecatedNodeTypesValidationService method validate.

public List<DeprecatedNodeTask> validate(Topology topology) {
    List<DeprecatedNodeTask> taskList = Lists.newArrayList();
    topology.getNodeTemplates().forEach((nodeTemplateName, nodeTemplate) -> {
        NodeType type = ToscaContext.get(NodeType.class, nodeTemplate.getType());
        if (isDeprecated(type)) {
            taskList.add(new DeprecatedNodeTask(nodeTemplateName, type));
        }
    });
    return taskList;
}
Also used : NodeType(org.alien4cloud.tosca.model.types.NodeType) DeprecatedNodeTask(alien4cloud.topology.task.DeprecatedNodeTask)

Aggregations

DeprecatedNodeTask (alien4cloud.topology.task.DeprecatedNodeTask)1 NodeType (org.alien4cloud.tosca.model.types.NodeType)1