rgw: fix up signal handling

OMG libfcgi is annoying with shutdown and signals.  You need to close
the fd *and* resend a signal to ensure that you kick the accept loop
hard enough to make it shut down.

Document this, and switch to the async signal handlers.  Put them
tightly around the runtime loop as we do with other daemons.

Signed-off-by: Sage Weil <sage@inktank.com>
(cherry picked from commit 59b13cebee600dad2551d2c7dc3482b05eaf8b22)
rgw: free resolver on shutdown

Signed-off-by: Sage Weil <sage@inktank.com>
(cherry picked from commit a31356338b8ae55df59d829d9080ffad70b97d10)
rgw: fix leak of RGWDataChangesLog::renew_thread

Signed-off-by: Sage Weil <sage@inktank.com>
(cherry picked from commit 25948319c4d256c4aeb0137eb88947e54d14cc79)
rgw: do not leak handler in get_handler() error path

If we fail to initialize, delete the handler.

Fixes (part of): #5949
Signed-off-by: Sage Weil <sage@inktank.com>
Reviewed-by: Yehuda Sadeh <yehuda@inktank.com>
(cherry picked from commit 810c52de36719c3ee6cf2bdf59d5cde8840bbe55)
rgw: drain requests before exiting

Fixes: #5953

Signed-off-by: Yehuda Sadeh <yehuda@inktank.com>
Reviewed-by: Sage Weil <sage@inktank.com>
(cherry picked from commit 3cbf6a7b031c2ce8072733c5c0b7ceb53fdcb090)