Fix OOM issues in qps tests (#26888)

pull/26254/head
Alisha Nanda 4 years ago committed by GitHub
parent eb6a4ae548
commit 0307759b9b
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
  1. 8
      test/cpp/qps/server_async.cc

@ -90,8 +90,12 @@ class AsyncQpsServerTest final : public grpc::testing::Server {
int num_threads = config.async_server_threads();
if (num_threads <= 0) { // dynamic sizing
num_threads = cores();
gpr_log(GPR_INFO, "Sizing async server to %d threads", num_threads);
num_threads = std::min(64, cores());
gpr_log(GPR_INFO,
"Sizing async server to %d threads. Defaults to number of cores "
"in machine or 64 threads if machine has more than 64 cores to "
"avoid OOMs.",
num_threads);
}
int tpc = std::max(1, config.threads_per_cq()); // 1 if unspecified

Loading…
Cancel
Save