Non blocking event dispatch (#652)

- Performance improvements for event dispatch
This commit is contained in:
Subin T P
2020-03-29 19:18:30 +05:30
committed by GitHub
parent bab9d663d2
commit e56132c506
6 changed files with 61 additions and 2 deletions

View File

@@ -0,0 +1,7 @@
class EventDispatcherJob < ApplicationJob
queue_as :events
def perform(event_name, timestamp, data)
Rails.configuration.dispatcher.async_dispatcher.publish_event(event_name, timestamp, data)
end
end