lib/flapjack/processor.rb in flapjack-1.1.0 vs lib/flapjack/processor.rb in flapjack-1.2.0rc1
- old
+ new
@@ -127,11 +127,11 @@
unless @should_quit
@should_quit = true
redis_uri = @redis_config[:path] ||
"redis://#{@redis_config[:host] || '127.0.0.1'}:#{@redis_config[:port] || '6379'}/#{@redis_config[:db] || '0'}"
shutdown_redis = EM::Hiredis.connect(redis_uri)
- shutdown_redis.rpush('events', Oj.dump('type' => 'noop'))
+ shutdown_redis.rpush('events', Flapjack.dump_json('type' => 'noop'))
end
end
private
@@ -149,10 +149,10 @@
@logger.debug("Processing Event: #{event_str}")
entity_check = Flapjack::Data::EntityCheck.for_event_id(event.id, :create_entity => true, :redis => @redis)
timestamp = Time.now.to_i
- event.tags = (event.tags || Flapjack::Data::TagSet.new) + entity_check.tags
+ event.tags = (event.tags || Set.new) + entity_check.tags
should_notify, previous_state = update_keys(event, entity_check, timestamp)
if !should_notify
@logger.debug("Not generating notification for event #{event.id} because filtering was skipped")