use of com.emc.storageos.isilon.restapi.IsilonSyncPolicyReport in project coprhd-controller by CoprHD.
the class IsilonFileStorageDevice method getSyncPolicyErrorReport.
/**
* get the error reports from device
*
* @param device - storage system
* @param syncPolicy - synciq policy name
* @return
*/
private BiosCommandResult getSyncPolicyErrorReport(StorageSystem device, IsilonSyncTargetPolicy policy) {
List<IsilonSyncPolicyReport> listMirrorPolicyReports = null;
StringBuffer errorMsgBuff = new StringBuffer();
errorMsgBuff.append(String.format("Policy details - failback-failover state : [%s] and policy status: [%s] ", policy.getFoFbState().toString(), policy.getLastJobState()));
// get policy reports from device.
IsilonApi isi = getIsilonDevice(device);
listMirrorPolicyReports = isi.getReplicationPolicyReports(policy.getName()).getList();
String errorMsg = mirrorOperations.isiGetReportErrMsg(listMirrorPolicyReports);
errorMsgBuff.append(String.format("Policy Error Report details: %s", errorMsg));
ServiceError serviceError = DeviceControllerErrors.isilon.unableToResyncPrepPolicy(device.getIpAddress(), policy.getName(), errorMsgBuff.toString());
_log.error(errorMsgBuff.toString());
return BiosCommandResult.createErrorResult(serviceError);
}
Aggregations