use of com.sequenceiq.cloudbreak.domain.view.OrchestratorView in project cloudbreak by hortonworks.
the class ClusterCreationService method startingAmbariServices.
public void startingAmbariServices(StackView stack) throws CloudbreakException {
OrchestratorView orchestrator = stack.getOrchestrator();
OrchestratorType orchestratorType = orchestratorTypeResolver.resolveType(orchestrator.getType());
stackUpdater.updateStackStatus(stack.getId(), DetailedStackStatus.STARTING_AMBARI_SERVICES, "Running cluster services.");
if (orchestratorType.containerOrchestrator()) {
flowMessageService.fireEventAndLog(stack.getId(), Msg.AMBARI_CLUSTER_RUN_CONTAINERS, UPDATE_IN_PROGRESS.name());
} else if (orchestratorType.hostOrchestrator()) {
flowMessageService.fireEventAndLog(stack.getId(), Msg.AMBARI_CLUSTER_RUN_SERVICES, UPDATE_IN_PROGRESS.name());
} else {
LOGGER.info(String.format("Please implement %s orchestrator because it is not on classpath.", orchestrator.getType()));
throw new CloudbreakException(String.format("Please implement %s orchestrator because it is not on classpath.", orchestrator.getType()));
}
}
Aggregations