public void rollback(final OMicroTransaction microTransaction) {
    try {
      checkOpenness();
      stateLock.acquireReadLock();
      try {
        try {
          checkOpenness();

          if (transaction.get() == null) {
            return;
          }

          if (transaction.get().getMicroTransaction().getId() != microTransaction.getId()) {
            throw new OStorageException(
                "Passed in and active micro-transaction are different micro-transactions. Passed in micro-transaction cannot be "
                    + "rolled back.");
          }

          makeStorageDirty();
          rollbackStorageTx();

          microTransaction.updateRecordCacheAfterRollback();

          txRollback.incrementAndGet();

        } catch (final IOException e) {
          throw OException.wrapException(new OStorageException("Error during micro-transaction rollback"), e);
        } finally {
          transaction.set(null);
        }
      } finally {
        stateLock.releaseReadLock();
      }
    } catch (final RuntimeException ee) {
      throw logAndPrepareForRethrow(ee);
    } catch (final Error ee) {
      throw logAndPrepareForRethrow(ee);
    } catch (final Throwable t) {
      throw logAndPrepareForRethrow(t);
    }
  }
public void rollback ( final OMicroTransaction microTransaction ) { try { checkOpenness ( ) ; stateLock . acquireReadLock ( ) ; try { try { checkOpenness ( ) ; if ( transaction . get ( ) == null ) { return ; } if ( transaction . get ( ) . getMicroTransaction ( ) . getId ( ) != microTransaction . getId ( ) ) { throw new OStorageException ( "Passed in and active micro-transaction are different micro-transactions. Passed in micro-transaction cannot be " + "rolled back." ) ; } makeStorageDirty ( ) ; rollbackStorageTx ( ) ; microTransaction . updateRecordCacheAfterRollback ( ) ; txRollback . incrementAndGet ( ) ; } catch ( final IOException e ) { throw OException . wrapException ( new OStorageException ( "Error during micro-transaction rollback" ) , e ) ; } finally { transaction . set ( null ) ; } } finally { stateLock . releaseReadLock ( ) ; } } catch ( final RuntimeException ee ) { throw logAndPrepareForRethrow ( ee ) ; } catch ( final Error ee ) { throw logAndPrepareForRethrow ( ee ) ; } catch ( final Throwable t ) { throw logAndPrepareForRethrow ( t ) ; } }
Rollbacks the given micro-transaction.

@param microTransaction the micro-transaction to rollback.