From: Casey Bodley Date: Fri, 30 Nov 2018 19:31:54 +0000 (-0500) Subject: rgw: RGWHTTPClient::wait() warns if it blocks in an asio thread X-Git-Tag: v15.0.0~27^2 X-Git-Url: http://git-server-git.apps.pok.os.sepia.ceph.com/?a=commitdiff_plain;h=refs%2Fpull%2F25355%2Fhead;p=ceph.git rgw: RGWHTTPClient::wait() warns if it blocks in an asio thread Signed-off-by: Casey Bodley --- diff --git a/src/rgw/rgw_http_client.cc b/src/rgw/rgw_http_client.cc index c3ea3e38a69b..8b36c2f78e86 100644 --- a/src/rgw/rgw_http_client.cc +++ b/src/rgw/rgw_http_client.cc @@ -17,6 +17,7 @@ #include "common/RefCountedObj.h" #include "rgw_coroutine.h" +#include "rgw_tools.h" #include @@ -76,6 +77,10 @@ struct rgw_http_req_data : public RefCountedObject { async_wait(context, yield[ec]); return -ec.value(); } + // work on asio threads should be asynchronous, so warn when they block + if (is_asio_thread) { + dout(20) << "WARNING: blocking http request" << dendl; + } #endif cond.Wait(lock); return ret;