[Groonga-commit] groonga/groonga-query-log at 6e4771f [master] replayer: extract consumer code

Back to archive index

Kouhei Sutou null+****@clear*****
Wed Sep 18 09:43:44 JST 2013


Kouhei Sutou	2013-09-18 09:43:44 +0900 (Wed, 18 Sep 2013)

  New Revision: 6e4771f90edd6aa356aff227f39400fc359d1e3e
  https://github.com/groonga/groonga-query-log/commit/6e4771f90edd6aa356aff227f39400fc359d1e3e

  Message:
    replayer: extract consumer code

  Modified files:
    lib/groonga/query-log/replayer.rb

  Modified: lib/groonga/query-log/replayer.rb (+6 -2)
===================================================================
--- lib/groonga/query-log/replayer.rb    2013-09-17 18:56:53 +0900 (4b6d82c)
+++ lib/groonga/query-log/replayer.rb    2013-09-18 09:43:44 +0900 (31be8b7)
@@ -62,6 +62,12 @@ module Groonga
       def run_consumers
         @options.n_clients.times.collect do
           Thread.new do
+            run_consumer
+          end
+        end
+      end
+
+      def run_consumer
             @options.create_client do |client|
               loop do
                 id, statistic =****@queue*****
@@ -72,8 +78,6 @@ module Groonga
                 replay_command(client, id, statistic.command)
               end
             end
-          end
-        end
       end
 
       def replay_command(client, id, command)
-------------- next part --------------
HTML����������������������������...
Download 



More information about the Groonga-commit mailing list
Back to archive index