}
} catch (BaseFaultType e) {
final String err =
CommonStrings.faultStringOrCommonCause(e, "ensemble");
throw new ExecutionProblem(err, e);
}
if (result.oneErrorExists) {
if (this.pr.enabled()) {
final String msg =
"Encountered a problem launching " + this.nameToPrint;
if (this.pr.useThis()) {
this.pr.infoln(PrCodes.ENSMONITOR__ONE_ERROR, msg);
} else if (this.pr.useLogging()) {
logger.info(msg);
}
}
} else if (result.allAtState) {
if (this.pr.enabled()) {
final String msg = this.nameToPrint + ": all members are " +
this.targetState.toString();
if (this.pr.useThis()) {
this.pr.infoln(PrCodes.ENSMONITOR__ALL_RUNNING,
" - " + msg);
} else if (this.pr.useLogging()) {
logger.info(msg);
}
}
} else {
throw new ExecutionProblem("Incorrect response from report query?");
}
if (result.workspaces == null) {
throw new ExecutionProblem("Incorrect response from report query?");
}
// both oneErrorExists and allRunning trigger report(s) if path is configured
if (this.args.reportDir != null) {
this.writeReports(result);