diff --git a/src/common/thread/GenericThreadPool.cpp b/src/common/thread/GenericThreadPool.cpp index a14eef354bb..3d68ec6e523 100644 --- a/src/common/thread/GenericThreadPool.cpp +++ b/src/common/thread/GenericThreadPool.cpp @@ -25,7 +25,8 @@ bool GenericThreadPool::start(size_t nrThreads, const std::string &name) { auto ok = true; for (auto i = 0UL; ok && i < nrThreads_; i++) { pool_.emplace_back(std::make_unique()); - ok = ok && pool_.back()->start(name); + auto workerName = folly::stringPrintf("%s-%lu", name.c_str(), i); + ok = ok && pool_.back()->start(std::move(workerName)); } return ok; }