for (ApiStackVersion apiStackVersionSummary : apiManager
.getStackVersionList(apiStack.getApiStackName().getStackName())
.getApiStackVersions()) {
ApiStackVersionInfo apiStackVersionInfoSummary =
apiStackVersionSummary.getApiStackVersionInfo();
ApiStackVersion apiStackVersion =
apiManager.getStackVersion(
apiStackVersionInfoSummary.getStackName(),
apiStackVersionInfoSummary.getStackVersion());
ApiStackVersionInfo apiStackVersionInfo =
apiStackVersion.getApiStackVersionInfo();
if (apiStackVersionInfo.isActive()) {
HadoopStack hadoopStack = new HadoopStack();
hadoopStack.setDistro(apiStackVersionInfo.getStackName(),
apiStackVersionInfo.getStackVersion());
hadoopStack