Sha256: 700faaf76df950f431645dae7988545b83d6d00243b90922221cd1f60cd1eb6e
Contents?: true
Size: 696 Bytes
Versions: 2
Compression:
Stored size: 696 Bytes
Contents
require 'active_job/arguments' module ActiveJob module Arguments extend self def deserialize_global_id(hash) # For non database based processors like sidekiq, the reactor may trigger before the # transaction is committed. Attempt to wait for the transaction to be commited before # running the reactor. This is not a perfect solution, but it's better than nothing. if Eventsimple.configuration.retry_reactor_on_record_not_found Retriable.with_context(:reactor) do ApplicationRecord.uncached { GlobalID::Locator.locate hash[GLOBALID_KEY] } end else GlobalID::Locator.locate hash[GLOBALID_KEY] end end end end
Version data entries
2 entries across 2 versions & 1 rubygems
Version | Path |
---|---|
eventsimple-1.1.3 | lib/eventsimple/active_job/arguments.rb |
eventsimple-1.1.2 | lib/eventsimple/active_job/arguments.rb |