public BiosCommandResult doFailBack(StorageSystem primarySystem,StorageSystem secondarySystem,String policyName,TaskCompleter taskCompleter){
  String mirrorPolicyName=policyName.concat("_mirror");
  BiosCommandResult result;
  try {
    result=isiResyncPrep(primarySystem,secondarySystem,policyName,null);
    if (!result.isCommandSuccess()) {
      return result;
    }
    result=doStartReplicationPolicy(secondarySystem,mirrorPolicyName,null);
    if (!result.isCommandSuccess()) {
      return result;
    }
    result=doFailover(primarySystem,mirrorPolicyName,null);
    if (!result.isCommandSuccess()) {
      return result;
    }
    result=isiResyncPrep(secondarySystem,primarySystem,mirrorPolicyName,null);
    if (!result.isCommandSuccess()) {
      return result;
    }
    _log.info("Failback from cluster {} to cluster {} successfully finished",secondarySystem.getIpAddress(),primarySystem.getIpAddress());
    return BiosCommandResult.createSuccessfulResult();
  }
 catch (  IsilonException e) {
    return BiosCommandResult.createErrorResult(e);
  }
}

public BiosCommandResult doFailBack ( StorageSystem primarySystem , StorageSystem secondarySystem , String policyName , TaskCompleter taskCompleter ) { String mirrorPolicyName = policyName . concat ( "_mirror" ) ; BiosCommandResult result ; try { result = isiResyncPrep ( primarySystem , secondarySystem , policyName , null ) ; if ( ! result . isCommandSuccess ( ) ) { return result ; } result = doStartReplicationPolicy ( secondarySystem , mirrorPolicyName , null ) ; if ( ! result . isCommandSuccess ( ) ) { return result ; } result = doFailover ( primarySystem , mirrorPolicyName , null ) ; if ( ! result . isCommandSuccess ( ) ) { return result ; } result = isiResyncPrep ( secondarySystem , primarySystem , mirrorPolicyName , null ) ; if ( ! result . isCommandSuccess ( ) ) { return result ; } _log . info ( "Failback from cluster {} to cluster {} successfully finished" , secondarySystem . getIpAddress ( ) , primarySystem . getIpAddress ( ) ) ; return BiosCommandResult . createSuccessfulResult ( ) ; } catch ( IsilonException e ) { return BiosCommandResult . createErrorResult ( e ) ; } }
call to device to fail back policy
