examples/producer.rb in songkick_queue-0.5.0 vs examples/producer.rb in songkick_queue-0.6.0

- old
+ new

@@ -8,8 +8,13 @@ SongkickQueue.configure do |config| config.host = 'localhost' config.logger = Logger.new(STDOUT) end +ActiveSupport::Notifications.subscribe('produce_message.songkick_queue') do |*args| + event = ActiveSupport::Notifications::Event.new(*args) + SongkickQueue.configuration.logger.info "name: #{event.name}, duration: #{event.duration}, payload: #{event.payload}" +end + 3.times do SongkickQueue.publish('notifications-service.tweets', { text: 'Hello world', user_id: 57237722 }) end