[Groonga-commit] droonga/droonga-engine at b155b66 [master] Show default number of slices

Back to archive index

YUKI Hiroshi null+****@clear*****
Sat Jun 28 03:32:19 JST 2014


YUKI Hiroshi	2014-06-28 03:32:19 +0900 (Sat, 28 Jun 2014)

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

  Message:
    Show default number of slices

  Modified files:
    bin/droonga-engine-catalog-generate
    lib/droonga/catalog_generator.rb

  Modified: bin/droonga-engine-catalog-generate (+2 -1)
===================================================================
--- bin/droonga-engine-catalog-generate    2014-06-28 03:30:41 +0900 (bbc9d94)
+++ bin/droonga-engine-catalog-generate    2014-06-28 03:32:19 +0900 (1abb140)
@@ -67,7 +67,8 @@ parser.on("--tag=TAG",
   current_dataset[:tag] = tag
 end
 parser.on("--n-slices=N", Integer,
-          "Use N slices for each replica.") do |n|
+          "Use N slices for each replica.",
+          "(#{Droonga::CatalogGenerator::DEFAULT_N_SLICES})") do |n|
   current_dataset[:n_slices] = n
 end
 parser.on("--plugins=PLUGIN1,PLUGIN2,...", Array,

  Modified: lib/droonga/catalog_generator.rb (+2 -1)
===================================================================
--- lib/droonga/catalog_generator.rb    2014-06-28 03:30:41 +0900 (28d6fd3)
+++ lib/droonga/catalog_generator.rb    2014-06-28 03:32:19 +0900 (0407d49)
@@ -20,6 +20,7 @@ module Droonga
     DEFAULT_DATASET = "Default"
     DEFAULT_HOSTS = ["127.0.0.1"]
     DEFAULT_N_WORKERS = 4
+    DEFAULT_N_SLICES = 1
     DEFAULT_PLUGINS = ["groonga", "search", "crud", "dump", "system"]
     DEFAULT_PORT = 10031
     DEFAULT_TAG = "droonga"
@@ -151,7 +152,7 @@ module Droonga
         @host       = host
         @port       = options[:port]     || DEFAULT_PORT
         @tag        = options[:tag]      || DEFAULT_TAG
-        @n_slices   = options[:n_slices] || 1
+        @n_slices   = options[:n_slices] || DEFAULT_N_SLICES
 
         @n_volumes = 0
       end
-------------- next part --------------
HTML����������������������������...
下载 



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