public DriverTask splitVolumeMirror(List<VolumeMirror> mirrors){
  LOG.info("Splitting volume mirror");
  DellSCDriverTask task=new DellSCDriverTask("splitVolumeMirror");
  StringBuilder errBuffer=new StringBuilder();
  int mirrorSplit=0;
  for (  VolumeMirror mirror : mirrors) {
    try {
      StorageCenterAPI api=connectionManager.getConnection(mirror.getStorageSystemId());
      api.deleteMirror(mirror.getNativeId());
      task.setStatus(TaskStatus.READY);
      mirrorSplit++;
    }
 catch (    StorageCenterAPIException|DellSCDriverException dex) {
      String error=String.format("Error splitting volume mirror %s: %s",mirror.getDisplayName(),dex);
      LOG.error(error);
      errBuffer.append(String.format("%s%n",error));
    }
  }
  task.setMessage(errBuffer.toString());
  if (mirrorSplit == mirrors.size()) {
    task.setStatus(TaskStatus.READY);
  }
 else   if (mirrorSplit == 0) {
    task.setStatus(TaskStatus.FAILED);
  }
 else {
    task.setStatus(TaskStatus.PARTIALLY_FAILED);
  }
  return task;
}

public DriverTask splitVolumeMirror ( List < VolumeMirror > mirrors ) { LOG . info ( "Splitting volume mirror" ) ; DellSCDriverTask task = new DellSCDriverTask ( "splitVolumeMirror" ) ; StringBuilder errBuffer = new StringBuilder ( ) ; int mirrorSplit = 0 ; for ( VolumeMirror mirror : mirrors ) { try { StorageCenterAPI api = connectionManager . getConnection ( mirror . getStorageSystemId ( ) ) ; api . deleteMirror ( mirror . getNativeId ( ) ) ; task . setStatus ( TaskStatus . READY ) ; mirrorSplit ++ ; } catch ( StorageCenterAPIException | DellSCDriverException dex ) { String error = String . format ( "Error splitting volume mirror %s: %s" , mirror . getDisplayName ( ) , dex ) ; LOG . error ( error ) ; errBuffer . append ( String . format ( "%s%n" , error ) ) ; } } task . setMessage ( errBuffer . toString ( ) ) ; if ( mirrorSplit == mirrors . size ( ) ) { task . setStatus ( TaskStatus . READY ) ; } else if ( mirrorSplit == 0 ) { task . setStatus ( TaskStatus . FAILED ) ; } else { task . setStatus ( TaskStatus . PARTIALLY_FAILED ) ; } return task ; }
delete volume mirror but leave the destination volume intact .
