apiManager.deleteCluster(clusterName);
if (isBlueprintCreated(clusterDef) && isBlueprintCreatedByBDE(clusterDef)) {
apiManager.deleteBlueprint(clusterName);
}
ApiPersist persist = new ApiPersist("");
apiManager.updatePersist(persist);
return true;
} catch (Exception e) {
logger.error("Ambari got an exception when deleting cluster", e);
throw SoftwareManagementPluginException.DELETE_CLUSTER_FAILED(e, Constants.AMBARI_PLUGIN_NAME,clusterBlueprint.getName());