summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorDmitry Antipov <dmantipov@yandex.ru>2020-05-18 18:49:19 +0300
committerDmitry Antipov <dmantipov@yandex.ru>2020-05-18 18:59:05 +0300
commitd3538f3c32a702c4bdcd747d1d44ac49e0da127a (patch)
tree35f34a559fc105b1056589ca0ead35082006887f
parent8e550380f7098275452fc26c46489739aa8bdae6 (diff)
storage/posix: fix thread name to comply with common convention
Rename disk space checking thread to comply with common convention, adjust related docs as well. Change-Id: I36d642cf09773a28abd95bbe337ce29134ad96a4 Signed-off-by: Dmitry Antipov <dmantipov@yandex.ru> Fixes: #1248
-rw-r--r--doc/developer-guide/thread-naming.md5
-rw-r--r--xlators/storage/posix/src/posix-helpers.c2
2 files changed, 4 insertions, 3 deletions
diff --git a/doc/developer-guide/thread-naming.md b/doc/developer-guide/thread-naming.md
index 74efba28e45..513140d4437 100644
--- a/doc/developer-guide/thread-naming.md
+++ b/doc/developer-guide/thread-naming.md
@@ -29,10 +29,10 @@ gf_thread_create_detached (pthread_t *thread,
As max name length for a thread in POSIX is only 16 characters including the
'\0' character, you have to be a little creative with naming. Also, it is
important that all Gluster threads have common prefix. Considering these
-conditions, we have "gluster" as prefix for all the threads created by these
+conditions, we have "glfs_" as prefix for all the threads created by these
wrapper functions. It is responsibility of the owner of thread to provide the
suffix part of the name. It does not have to be a descriptive name, as it has
-only 8 letters to work with. However, it should be unique enough such that it
+only 10 letters to work with. However, it should be unique enough such that it
can be matched with a table which describes it.
If n number of threads are spwaned to perform same function, it is must that the
@@ -87,6 +87,7 @@ such that it can be matched with a table below without ambiguity.
- posixfsy - posix fsync
- posixhc - posix heal
- posixjan - posix janitor
+- posixrsv - posix reserve
- quiesce - quiesce dequeue
- rdmaAsyn - rdma async event handler
- rdmaehan - rdma completion handler
diff --git a/xlators/storage/posix/src/posix-helpers.c b/xlators/storage/posix/src/posix-helpers.c
index b25855bbfbd..513a2f0a2b4 100644
--- a/xlators/storage/posix/src/posix-helpers.c
+++ b/xlators/storage/posix/src/posix-helpers.c
@@ -2315,7 +2315,7 @@ posix_spawn_disk_space_check_thread(xlator_t *xl)
ret = gf_thread_create(&priv->disk_space_check, NULL,
posix_disk_space_check_thread_proc, xl,
- "posix_reserve");
+ "posixrsv");
if (ret) {
priv->disk_space_check_active = _gf_false;
gf_msg(xl->name, GF_LOG_ERROR, errno, P_MSG_DISK_SPACE_CHECK_FAILED,