]> git-server-git.apps.pok.os.sepia.ceph.com Git - ceph.git/commitdiff
rgw: configurable thread pool size
authorYehuda Sadeh <yehuda@hq.newdream.net>
Thu, 1 Sep 2011 18:39:59 +0000 (11:39 -0700)
committerYehuda Sadeh <yehuda@hq.newdream.net>
Thu, 1 Sep 2011 18:39:59 +0000 (11:39 -0700)
src/common/config.cc
src/common/config.h
src/rgw/rgw_main.cc

index c75e066b51f31dd7dd6602b5c92773c1d344c9cb..c1d99d1412ddafcc94a693a582e41354dd6415c2 100644 (file)
@@ -433,6 +433,7 @@ struct config_option config_optionsp[] = {
   OPTION(rgw_socket_path, OPT_STR, NULL),   // path to unix domain socket, if not specified, rgw will not run as external fcgi
   OPTION(rgw_op_thread_timeout, OPT_INT, 10*60),
   OPTION(rgw_op_thread_suicide_timeout, OPT_INT, 60*60),
+  OPTION(rgw_thread_pool_size, OPT_INT, 100),
 
   // see config.h
   OPTION(internal_safe_to_start_threads, OPT_BOOL, false),
index 1d4bfbfc9bece3e0aeda5d4960faeb6f6ffcd8c8..644cc1d6be1a6d7acc1a150761bf6539d7fa2d53 100644 (file)
@@ -567,6 +567,7 @@ public:
   string rgw_socket_path;
   int rgw_op_thread_timeout;
   int rgw_op_thread_suicide_timeout;
+  int rgw_thread_pool_size;
 
   // This will be set to true when it is safe to start threads.
   // Once it is true, it will never change.
index 3a6b833a524f8926ae8c97e277a4ee2ff9daf71b..1ab2219e556b10d46665b68538a7311acf78f195 100644 (file)
@@ -253,7 +253,7 @@ int main(int argc, const char **argv)
     return EIO;
   }
 
-  RGWProcess process(g_ceph_context, 20);
+  RGWProcess process(g_ceph_context, g_conf->rgw_thread_pool_size);
 
   process.run();