[Groonga-commit] groonga/fluent-plugin-droonga at e13fdf5 [master] Divide Proxy::dispatch.

Back to archive index

Daijiro MORI null+****@clear*****
Thu Aug 15 09:15:11 JST 2013


Daijiro MORI	2013-08-15 09:15:11 +0900 (Thu, 15 Aug 2013)

  New Revision: e13fdf57fa6a5502ed92916fd44be7d802eeab9f
  https://github.com/groonga/fluent-plugin-droonga/commit/e13fdf57fa6a5502ed92916fd44be7d802eeab9f

  Message:
    Divide Proxy::dispatch.

  Modified files:
    lib/droonga/proxy.rb

  Modified: lib/droonga/proxy.rb (+8 -11)
===================================================================
--- lib/droonga/proxy.rb    2013-08-14 22:28:38 +0900 (92be2cb)
+++ lib/droonga/proxy.rb    2013-08-15 09:15:11 +0900 (00e04fd)
@@ -50,25 +50,22 @@ module Droonga
       end
     end
 
+    def handle_internal_message(message)
+      components = message["components"]
+      @planner = Planner.new(self, components) unless @planner
+      dispatch_internal(message)
+    end
+
     def dispatch(destination, message)
       if destination =~ @local
-        if message["input"]
-          collector = @collectors[message["id"]]
-          collector.handle(message["input"], message["value"])
-        else
-          collector =****@plann*****_collector(message["id"], @local)
-          @collectors[message["id"]] = collector
-          collector.handle(nil, nil)
-        end
+        dispatch_internal(message)
       else
         destination =~ /\A.*:\d+\/[^\.]+/
         post($&, message)
       end
     end
 
-    def handle_internal_message(message)
-      components = message["components"]
-      @planner = Planner.new(self, components) unless @planner
+    def dispatch_internal(message)
       if message["input"]
         # received a piece of result
         collector = @collectors[message["id"]]
-------------- next part --------------
HTML����������������������������...
Download 



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