code: @Override
      public void commit()
          throws HeuristicMixedException,
                 HeuristicRollbackException,
                 RollbackException,
                 SystemException
      {
          try {
              if (!Context.isTMNoTransaction()) {
                  if (Context.isTMActive()) {
                      Context.commit();
                  } else {
                      Context.rollback();
                  }
              }
          } catch (final EFapsException e) {
              throw new SystemException(e.getMessage());
          }
      }
docs: Commit.
  
  @see javax.transaction.UserTransaction#commit()
  @throws HeuristicMixedException on error
  @throws HeuristicRollbackException on error
  @throws RollbackException on error
  @throws SystemException on error