Opens a new transaction against all registered backend system wrapped in one {@link BackendTransaction}.

@return
@throws BackendException
774788
public BackendTransaction beginTransaction(TransactionConfiguration configuration, KeyInformation.Retriever indexKeyRetriever) throws BackendException {

        StoreTransaction tx = storeManagerLocking.beginTransaction(configuration);

        // Cache
        CacheTransaction cacheTx = new CacheTransaction(tx, storeManagerLocking, bufferSize, maxWriteTime, configuration.hasEnabledBatchLoading());

        // Index transactions
        Map<String, IndexTransaction> indexTx = new HashMap<String, IndexTransaction>(indexes.size());
        for (Map.Entry<String, IndexProvider> entry : indexes.entrySet()) {
            indexTx.put(entry.getKey(), new IndexTransaction(entry.getValue(), indexKeyRetriever.get(entry.getKey()), configuration, maxWriteTime));
        }

        return new BackendTransaction(cacheTx, configuration, storeFeatures,
                edgeStore, indexStore, txLogStore,
                maxReadTime, indexTx, threadPool);
    }
866518
protected boolean beginTransaction(SQLiteDatabase db) {
		boolean endTransaction = false;
		if (!db.inTransaction()) {
			db.beginTransaction();
			endTransaction = true;
			LOGGER.trace("Begin transaction");
		}
		return endTransaction;
	}
192019
private Transaction onBegin()
    {
        Transaction tx;
        if (((StatelessSessionImpl) s).getTransactionCoordinator().isTransactionActive())
        {
            tx = ((StatelessSessionImpl) s).getTransaction();
        }
        else
        {
            tx = s.beginTransaction();
        }
        return tx;
    }
364302
public function beginTransaction()
    {
        if ($this->disableTransactionHandling) {
            return;
        }

        if (null !== $this->session) {
            throw new \RuntimeException('Transaction already started');
        }
        $this->session = $this->mongoClient->startSession();
        $this->session->startTransaction([
            'readConcern' => new \MongoDB\Driver\ReadConcern('snapshot'),
            'writeConcern' => new \MongoDB\Driver\WriteConcern(\MongoDB\Driver\WriteConcern::MAJORITY),
        ]);
    }
1187361
public boolean addTransactionAware(TransactionAware txAware) {
    // If the txAware is newly added, call startTx as well if there is an active transaction
    boolean added = txAwares.add(txAware);
    if (added && currentTx != null) {
      txAware.startTx(currentTx);
    }
    return added;
  }
125380
public Index open(Transaction tx) {
		TableInfo ti = VanillaDb.catalogMgr().getTableInfo(tblName, tx);
		if (ti == null)
			throw new TableNotFoundException("table '" + tblName
					+ "' is not defined in catalog.");

		return Index.newInstance(this, new SearchKeyType(ti.schema(), fldNames), tx);
	}
595900
public function beginTransaction()
    {
        if ( $this->link == null ) {
            $this->connect();
        }
        ++$this->transactions;

        if ( $this->transactions == 1 ) {
            $this->link->beginTransaction();
        }


    }
1033401
private function dbExec()
    {
        if ($this->transLevel > 0
            && $this->transLevelRolledBack[$this->transLevel]
        ) {
            throw $this->createException('Trying to run query in rolled back transaction');
        }

        if (!empty($this->pendingTransactionBegin[$this->transLevel])) {
            $this->dbBeginTransaction();
        } else {
            if ($this->pendingConnection) {
                $this->connect();
            }
        }

        $result = pg_query($this->pgConn, $this->currentQuery);

        if ($result !== false) {
            return new DB\Result($result, $this->oidTypeNames);
        }

        if ($this->isInDbTransaction()) {
            $this->dbRollback();
            $this->transLevelRolledBack[$this->transLevel] = true;
        }

        throw $this->createException();
    }
737497
@Override
	protected FlinkKafkaProducer.KafkaTransactionState beginTransaction() throws FlinkKafkaException {
		switch (semantic) {
			case EXACTLY_ONCE:
				FlinkKafkaInternalProducer<byte[], byte[]> producer = createTransactionalProducer();
				producer.beginTransaction();
				return new FlinkKafkaProducer.KafkaTransactionState(producer.getTransactionalId(), producer);
			case AT_LEAST_ONCE:
			case NONE:
				// Do not create new producer on each beginTransaction() if it is not necessary
				final FlinkKafkaProducer.KafkaTransactionState currentTransaction = currentTransaction();
				if (currentTransaction != null && currentTransaction.producer != null) {
					return new FlinkKafkaProducer.KafkaTransactionState(currentTransaction.producer);
				}
				return new FlinkKafkaProducer.KafkaTransactionState(initNonTransactionalProducer(true));
			default:
				throw new UnsupportedOperationException("Not implemented semantic");
		}
	}
664301
@Override
	public AppEngineTransaction beginTransaction() {
		if (isTransactional()) {
			throw new IllegalStateException("Transaction has already started ["
					+ transaction.get().id() + "]");
		}
		
		AppEngineTransaction tx = new AppEngineTransaction(this);
		transaction.set(tx);
		logger.fine("Transaction [" + transaction.get().id() + "] started");
		return tx;
	}
659462
public TransactionContext createTransactionContext() {
    transactionContext = dataFabricFacade.createTransactionManager();
    for (TransactionAware transactionAware : transactionAwares) {
      this.transactionContext.addTransactionAware(transactionAware);
    }
    return transactionContext;
  }
813465
public void commitTransaction() throws SystemException
   {
      Long key = Long.valueOf(Thread.currentThread().getId());
      TransactionImpl tx = txs.get(key);
      if (tx != null)
      {
         try
         {
            tx.commit();
         }
         catch (Throwable t)
         {
            SystemException se = new SystemException("Error during commit");
            se.initCause(t);
            throw se;
         }
      }
      else
      {
         throw new IllegalStateException("No transaction to commit");
      }
   }
1276451
public function beginTransaction() {
		if ($this->inTransaction()) {
			throw new Exception('Transaction already is active');
		}
		$this->_inTransaction = true;
		$this->_commitMode = (PHP_VERSION_ID >= 503020) ? OCI_NO_AUTO_COMMIT : OCI_DEFAULT;

		return true;
	}
1360655
public void rollbackTransaction() throws HibernateException
    {
        Transaction tx = threadTransaction.get();
        try
        {
            threadTransaction.set(null);
            if (tx != null && !tx.wasCommitted() && !tx.wasRolledBack())
            {
                tx.rollback();
            }
        }
        finally
        {
            closeSession();
        }
    }
1351839
public function beginTransaction()
    {
        try {
            $this->gateway->beginTransaction();
        } catch (\RuntimeException $e) {
            throw new OrmException("Unable to start transaction.\n" . $e->getMessage(), 0, $e);
        }
    }
1225742
function begin() {
		$this->dbh or $this->setup();

		if ($this->savepoint == 0) {
			$this->dbh->beginTransaction();
		}
		else { // already in a transaction
			$this->dbh->exec('SAVEPOINT save'.$this->savepoint);
		}

		$this->savepoint++;
		return $this;
	}
411974
public Transaction beginTransaction() {
		if (datastoreType == DatastoreType.HIGH_REPLICATION) {
			return datastore.beginTransaction(TransactionOptions.Builder.withXG(true));
		}
		
		return datastore.beginTransaction();
	}