function TransactionManagerBase::processRootRollback

Same name and namespace in other branches
  1. 11.x core/lib/Drupal/Core/Database/Transaction/TransactionManagerBase.php \Drupal\Core\Database\Transaction\TransactionManagerBase::processRootRollback()
  2. 10 core/lib/Drupal/Core/Database/Transaction/TransactionManagerBase.php \Drupal\Core\Database\Transaction\TransactionManagerBase::processRootRollback()

Processes the root transaction rollback.

1 call to TransactionManagerBase::processRootRollback()
TransactionManagerBase::rollback in core/lib/Drupal/Core/Database/Transaction/TransactionManagerBase.php

File

core/lib/Drupal/Core/Database/Transaction/TransactionManagerBase.php, line 623

Class

TransactionManagerBase
The database transaction manager base class.

Namespace

Drupal\Core\Database\Transaction

Code

protected function processRootRollback() : void {
  try {
    if (!$this->rollbackClientTransaction()) {
      throw new TransactionException('Transaction rollback failed');
    }
  } catch (TransactionException $e) {
    $this->setConnectionTransactionState(ClientConnectionTransactionState::RollbackFailed);
    throw $e;
  }
  $this->setConnectionTransactionState(ClientConnectionTransactionState::RolledBack);
}

Buggy or inaccurate documentation? Please file an issue. Need support? Need help programming? Connect with the Drupal community.