From: Yehuda Sadeh Date: Thu, 1 Sep 2011 18:39:59 +0000 (-0700) Subject: rgw: configurable thread pool size X-Git-Tag: v0.35~136 X-Git-Url: http://git-server-git.apps.pok.os.sepia.ceph.com/?a=commitdiff_plain;h=4fa62d5e02ca0c065ab9fedeeb7311de4d989324;p=ceph.git rgw: configurable thread pool size --- diff --git a/src/common/config.cc b/src/common/config.cc index c75e066b51f3..c1d99d1412dd 100644 --- a/src/common/config.cc +++ b/src/common/config.cc @@ -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), diff --git a/src/common/config.h b/src/common/config.h index 1d4bfbfc9bec..644cc1d6be1a 100644 --- a/src/common/config.h +++ b/src/common/config.h @@ -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. diff --git a/src/rgw/rgw_main.cc b/src/rgw/rgw_main.cc index 3a6b833a524f..1ab2219e556b 100644 --- a/src/rgw/rgw_main.cc +++ b/src/rgw/rgw_main.cc @@ -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();