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
..
2018-03-01 07:02:35 +00:00
2015-10-23 18:51:29 +11:00
2019-08-28 15:35:00 -05:00
2019-08-28 15:35:00 -05:00