method

begin_transaction

Importance_0
v5.0.0.1 - Show latest stable - 0 notes - Class: TransactionManager
begin_transaction(options = {}) public

No documentation

This method has no description. You can help the Ruby on Rails community by adding new notes.

Hide source
# File activerecord/lib/active_record/connection_adapters/abstract/transaction.rb, line 154
      def begin_transaction(options = {})
        run_commit_callbacks = !current_transaction.joinable?
        transaction =
          if @stack.empty?
            RealTransaction.new(@connection, options, run_commit_callbacks: run_commit_callbacks)
          else
            SavepointTransaction.new(@connection, "active_record_#{@stack.size}", options,
                                     run_commit_callbacks: run_commit_callbacks)
          end

        @stack.push(transaction)
        transaction
      end
Register or log in to add new notes.