code: private ProcessInstance getProcInstFromDB(Long procInstId) throws DataAccessException {
          TransactionWrapper transaction = null;
          EngineDataAccessDB edao = new EngineDataAccessDB();
          try {
              transaction = edao.startTransaction();
              return edao.getProcessInstance(procInstId);
          } catch (SQLException e) {
              logger.severe("InvokeSubProcessActivity -> Failed to load process instance for " + procInstId);
              return null;
          } finally {
              edao.stopTransaction(transaction);
          }
      }
docs: Method to get the Process Instance from the database
  @param procInstId
  @return
  @throws DataAccessException