Module: TorqueBox::Transactions::Transaction

Included in:
Manager
Defined in:
transactions/lib/torquebox/transactions.rb

Instance Method Summary (collapse)

Instance Method Details

- (Object) commit



40
41
42
# File 'transactions/lib/torquebox/transactions.rb', line 40

def commit
  @tm.commit
end

- (Object) error(exception)



48
49
50
51
52
# File 'transactions/lib/torquebox/transactions.rb', line 48

def error( exception )
  puts "Transaction rollback: #{exception}"
  rollback
  raise
end

- (Object) prepare



36
37
38
# File 'transactions/lib/torquebox/transactions.rb', line 36

def prepare
  @tm.begin
end

- (Object) rollback



44
45
46
# File 'transactions/lib/torquebox/transactions.rb', line 44

def rollback
  @tm.rollback
end