method
all_open_transactions
v8.1.1 -
Show latest stable
- Class:
ActiveRecord
all_open_transactions()public
No documentation available.
# File activerecord/lib/active_record.rb, line 593
def self.all_open_transactions # :nodoc:
open_transactions = []
Base.connection_handler.each_connection_pool do |pool|
if active_connection = pool.active_connection
current_transaction = active_connection.current_transaction
if current_transaction.open? && current_transaction.joinable?
open_transactions << current_transaction
end
end
end
open_transactions
end