[Groonga-commit] droonga/droonga-engine at dbd1db3 [master] Accept scatter withotu record

Back to archive index

YUKI Hiroshi null+****@clear*****
Tue Apr 14 16:10:14 JST 2015


YUKI Hiroshi	2015-04-14 16:10:14 +0900 (Tue, 14 Apr 2015)

  New Revision: dbd1db3037eb2823d555a7e01fa08d2550fbc587
  https://github.com/droonga/droonga-engine/commit/dbd1db3037eb2823d555a7e01fa08d2550fbc587

  Message:
    Accept scatter withotu record

  Modified files:
    lib/droonga/catalog/slices_volume.rb

  Modified: lib/droonga/catalog/slices_volume.rb (+6 -1)
===================================================================
--- lib/droonga/catalog/slices_volume.rb    2015-04-14 16:06:27 +0900 (e3d7944)
+++ lib/droonga/catalog/slices_volume.rb    2015-04-14 16:10:14 +0900 (97847fc)
@@ -80,7 +80,12 @@ module Droonga
             routes.concat(slice.compute_routes(message, active_nodes))
           end
         when "scatter"
-          slice = choose_slice(message["record"])
+          record = message["record"]
+          if record
+            slice = choose_slice(record)
+          else
+            slice = select_slices.sample
+          end
           routes.concat(slice.compute_routes(message, active_nodes))
         end
         routes
-------------- next part --------------
HTML����������������������������...
Download 



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