private void unlock(){
  try {
    MPInstance mpi=new MPInstance(getCtx(),m_pi.getAD_PInstance_ID(),null);
    if (mpi.get_ID() == 0) {
      log.log(Level.SEVERE,"Did not find PInstance " + m_pi.getAD_PInstance_ID());
      return;
    }
    mpi.setIsProcessing(false);
    mpi.setResult(!m_pi.isError());
    mpi.setErrorMsg(m_pi.getSummary());
    mpi.saveEx();
    log.fine(mpi.toString());
    ProcessInfoUtil.saveLogToDB(m_pi);
  }
 catch (  Exception e) {
    log.severe("unlock() - " + e.getLocalizedMessage());
  }
}

private void unlock ( ) { try { MPInstance mpi = new MPInstance ( getCtx ( ) , m_pi . getAD_PInstance_ID ( ) , null ) ; if ( mpi . get_ID ( ) == 0 ) { log . log ( Level . SEVERE , "Did not find PInstance " + m_pi . getAD_PInstance_ID ( ) ) ; return ; } mpi . setIsProcessing ( false ) ; mpi . setResult ( ! m_pi . isError ( ) ) ; mpi . setErrorMsg ( m_pi . getSummary ( ) ) ; mpi . saveEx ( ) ; log . fine ( mpi . toString ( ) ) ; ProcessInfoUtil . saveLogToDB ( m_pi ) ; } catch ( Exception e ) { log . severe ( "unlock() - " + e . getLocalizedMessage ( ) ) ; } }
unlock process instance . update process instance db and write option return message
