oslo.privsep/oslo_privsep
Eric Fried e896ed39c4 Self-resetting PrivContext
When nova-compute, an oslo.service, receives SIGHUP, running PrivContext
clients terminate, resulting in the shutdown of their corresponding
ClientChannel threads. Subsequent attempts to execute privileged methods
fail with EPIPE as a result.

The PrivContext._wrap'per (the meat of the entrypoint decorator) already
had a check to lazily start() the ClientChannel if that hasn't already
happened.

This commit makes ClientChannel store state indicating whether it's
still running; and adds logic to PrivContext._wrap to check that state
and reset (stop() and re-start()) the ClientChannel if it was previously
created but terminated.

Change-Id: I8096fc7fd014e6dd299fae8ab073336c7cae362a
Closes-Bug: #1715374
2019-08-28 15:35:00 -05:00
..
locale Imported Translations from Zanata 2018-03-01 07:02:35 +00:00
tests Convert dict keys received in _ClientChannel from byte to str 2019-04-04 11:06:08 +00:00
__init__.py Initial cookiecutter project 2015-10-23 18:51:29 +11:00
_i18n.py Update URLs in documents according to document migration 2017-07-12 23:09:35 +08:00
capabilities.py Avoids calling ffi.dlopen(None) on Windows 2018-08-19 10:42:55 -07:00
comm.py Self-resetting PrivContext 2019-08-28 15:35:00 -05:00
daemon.py Pass correct arguments to six.reraise 2019-05-17 16:10:12 +00:00
priv_context.py Self-resetting PrivContext 2019-08-28 15:35:00 -05:00
version.py pbr.version.VersionInfo needs package name (oslo.xyz and not oslo_xyz) 2017-02-06 12:49:22 -05:00