[Groonga-commit] droonga/fluent-plugin-droonga at 096afe4 [master] Remove Proxy::dispatch_internal.

Back to archive index

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


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

  New Revision: 096afe4e5dfa30cf6dcfae780f75727d85fdf3c7
  https://github.com/droonga/fluent-plugin-droonga/commit/096afe4e5dfa30cf6dcfae780f75727d85fdf3c7

  Message:
    Remove Proxy::dispatch_internal.

  Modified files:
    lib/droonga/proxy.rb

  Modified: lib/droonga/proxy.rb (+10 -12)
===================================================================
--- lib/droonga/proxy.rb    2013-08-15 11:41:31 +0900 (7c37fae)
+++ lib/droonga/proxy.rb    2013-08-15 11:51:40 +0900 (7f4bece)
@@ -49,18 +49,6 @@ module Droonga
     end
 
     def handle_internal_message(message)
-      dispatch_internal(message)
-    end
-
-    def dispatch(destination, message)
-      if local?(destination)
-        dispatch_internal(message)
-      else
-        post(farm_path(destination), message)
-      end
-    end
-
-    def dispatch_internal(message)
       id = message["id"]
       collector = @collectors[id]
       unless collector
@@ -68,11 +56,21 @@ module Droonga
         if components
           planner = Planner.new(self, components)
           collector = planner.get_collector(id)
+        else
+          #todo: take cases receiving result before its query into account
         end
       end
       collector.handle(message["input"], message["value"])
     end
 
+    def dispatch(destination, message)
+      if local?(destination)
+        handle_internal_message(message)
+      else
+        post(farm_path(destination), message)
+      end
+    end
+
     def post(route, message)
       @worker.post(message, "to"=> route, "type"=>"proxy")
     end
-------------- next part --------------
HTML����������������������������...
다운로드 



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