YUKI Hiroshi
null+****@clear*****
Thu Nov 7 14:43:38 JST 2013
YUKI Hiroshi 2013-11-07 14:43:38 +0900 (Thu, 07 Nov 2013) New Revision: c5deec71d05fbcb6b7cbeacbad0a1a294630f273 https://github.com/droonga/fluent-plugin-droonga/commit/c5deec71d05fbcb6b7cbeacbad0a1a294630f273 Message: Reduce accesses to the database Modified files: lib/droonga/watcher.rb Modified: lib/droonga/watcher.rb (+3 -2) =================================================================== --- lib/droonga/watcher.rb 2013-11-07 14:43:23 +0900 (4339b1b) +++ lib/droonga/watcher.rb 2013-11-07 14:43:38 +0900 (664648a) @@ -185,8 +185,9 @@ module Droonga subscriber.subscriptions =~ query end subscribers.each do |subscriber| - routes[subscriber.route.key] ||= [] - routes[subscriber.route.key] << subscriber.key.key + route = subscriber.route.key + routes[route] ||= [] + routes[route] << subscriber.key.key end end routes.each do |route, subscribers| -------------- next part -------------- HTML����������������������������...Download