Merge "Reload logging options when receiving SIGHUP"

This commit is contained in:
Jenkins 2015-06-02 11:00:31 +00:00 committed by Gerrit Code Review
commit a54c655141
2 changed files with 9 additions and 0 deletions

View File

@ -397,6 +397,10 @@ class EngineService(service.Service):
LOG.info(_LI("All threads were gone, terminating engine"))
super(EngineService, self).stop()
def reset(self):
super(EngineService, self).reset()
logging.setup(cfg.CONF, 'heat')
@context.request_context
def identify_stack(self, cnxt, stack_name):
"""

View File

@ -3566,6 +3566,11 @@ class StackServiceTest(common.HeatTestCase):
admin_context_method
)
@mock.patch('oslo_log.log.setup')
def test_engine_service_reset(self, setup_logging_mock):
self.eng.reset()
setup_logging_mock.assertCalledOnceWith(cfg.CONF, 'heat')
class ThreadGroupManagerTest(common.HeatTestCase):
def setUp(self):