[Groonga-commit] droonga/drnbench at 0c61a2f [master] Rewrite description of each option.

アーカイブの一覧に戻る

SHIMODA Piro Hiroshi null+****@clear*****
Sat Oct 4 01:00:17 JST 2014


SHIMODA "Piro" Hiroshi	2014-10-04 01:00:17 +0900 (Sat, 04 Oct 2014)

  New Revision: 0c61a2f31b45a8a60125adb43e1c7169022f45d6
  https://github.com/droonga/drnbench/commit/0c61a2f31b45a8a60125adb43e1c7169022f45d6

  Message:
    Rewrite description of each option.

  Modified files:
    bin/drnbench-request-response

  Modified: bin/drnbench-request-response (+41 -19)
===================================================================
--- bin/drnbench-request-response    2014-10-04 00:59:19 +0900 (622bdcb)
+++ bin/drnbench-request-response    2014-10-04 01:00:17 +0900 (4ef243e)
@@ -23,70 +23,92 @@ config = Drnbench::RequestResponse::Configuration.new
 option_parser = OptionParser.new do |parser|
   parser.version = Drnbench::VERSION
 
+  parser.separator("")
   parser.on("--duration=SECONDS", Float,
-            "duration of the benmark") do |duration|
+            "Duration of each benchmark.",
+            "(#{config.duration})") do |duration|
     config.duration = duration
   end
   parser.on("--wait=SECONDS", Float,
-            "wait for each request") do |wait|
+            "Interval of each request sent by a client.",
+            "(#{config.wait})") do |wait|
     config.wait = wait
   end
+  parser.on("--n-slow-requests=N", Integer,
+            "Number of slow requests to be reported.",
+            "(#{config.n_slow_requests})") do |n_slow_requests|
+    config.n_slow_requests = n_slow_requests
+  end
+
+  parser.separator("")
+  parser.separator("Progressive benchmark:")
   parser.on("--interval=SECONDS", Float,
-            "interval for each gradual case") do |interval|
+            "Interval between each benchmark.",
+            "(#{config.interval})") do |interval|
     config.interval = interval
   end
   parser.on("--start-n-clients=N", Integer,
-            "initial number of clients (optional)") do |n_clients|
+            "Initial number of clients.",
+            "(#{config.start_n_clients})") do |n_clients|
     config.start_n_clients = n_clients
   end
   parser.on("--end-n-clients=N", Integer,
-            "final number of clients (optional)") do |n_clients|
+            "Maximum number of clients.",
+            "(#{config.end_n_clients})") do |n_clients|
     config.end_n_clients = n_clients
   end
   parser.on("--step=COUNT", Integer,
-            "step to increase number of clients (optional)") do |step|
+            "Number of clients increased on each",
+            "progress.",
+            "(#{config.step})") do |step|
     config.step = step
   end
-  parser.on("--n-slow-requests=N", Integer,
-            "number of reporting slow requests (optional)") do |n_slow_requests|
-    config.n_slow_requests = n_slow_requests
-  end
 
+  parser.separator("")
+  parser.separator("Request:")
   parser.on("--mode=MODE", String,
-            "mode of benchmark (optional)",
+            "Request mode.",
             "available modes:",
-            "  http",
+            "  http (default)",
             "  http-droonga-search") do |mode|
     config.mode = mode.gsub(/-/, "_")
   end
   parser.on("--request-patterns-file=PATH",
-            "path to request patterns JSON file") do |path|
+            "Path to request patterns JSON file.") do |path|
     config.request_patterns_file = File.expand_path(path)
   end
 
   parser.on("--default-host=HOST", String,
-            "default host name (optional)") do |host|
+            "Default host name for each request.",
+            "(#{config.default_host})") do |host|
     config.default_host = host
   end
   parser.on("--default-port=PORT", Integer,
-            "default port number (optional)") do |port|
+            "Default port number for each request.",
+            "(#{config.default_port})") do |port|
     config.default_port = port
   end
   parser.on("--default-path=PATH", String,
-            "default path (optional)") do |path|
+            "Default path for each request",
+            "(#{config.default_path})") do |path|
     config.default_path = path
   end
   parser.on("--default-method=METHOD", String,
-            "default HTTP method (optional)") do |method|
+            "Default HTTP method for each request.",
+            "(#{config.default_method})") do |method|
     config.default_method = method
   end
   parser.on("--default-timeout=SECONDS", Float,
-            "default timeout (optional)") do |timeout|
+            "Default timeout for each request.",
+            "(#{config.default_timeout})") do |timeout|
     config.default_timeout = timeout
   end
 
+  parser.separator("")
+  parser.separator("Output:")
   parser.on("--output-path=PATH",
-            "path to output statistics as a CSV file (optional)") do |path|
+            "Path to output statistics as a CSV file.",
+            "(#{config.output_path})") do |path|
     config.output_path = File.expand_path(path)
   end
 end
-------------- next part --------------
HTML����������������������������...
ダウンロード 



More information about the Groonga-commit mailing list
アーカイブの一覧に戻る