code: public void commit(DBTransaction transaction) {
          try {
              applyUpdates(transaction);
          } catch (Exception e) {
              m_logger.error("Updates failed", e);
              throw e;
          } finally {
              transaction.clear();
          }
      }
docs: Apply the updates accumulated in this transaction. The updates are cleared even if
  the update fails.