Active Record transaction callbacks | Greg Molnar

Active Record introduced transaction callbacks recently. This change allows you to have a callback for the whole transaction, rather than to just have callbacks on a record’s after_commit event. To make this possible, ActiveRecord::Base.transaction yields a transaction object now and the callback.
Active Record transaction callbacks | Greg Molnar #ruby #rubydeveloper #rubyonrails #active #callbacks #record https://rubyonrails.ba/single/active-record-transaction-callbacks-greg-molnar

Nezir Zahirovic

Contractor Ruby On Rails (8+ years) / MCPD .Net / C# / Asp.Net / CSS / SQL / (11 years)

related articles