Enable mutable config in Tricircle

1. What is the problem?

   The oslo.config support a 'mutable' parameter to Opts.
   This is only respected when the new method mutate_config_files
   is called instead of reload_config_files.so we need to enable
   mutable config in tricircle.

2. What is the solution to the problem?

   Depend on the two path in oslo.config which are
   Icec3e664f3fe72614e373b2938e8dee53cf8bc5e and
   I1e7a69de169cc85f4c09954b2f46ce2da7106d90 made the Tricircle
   have the ability to mutable config.

3. What the features to be implemented in the Tricircle to realize the solution?

   Further patches will be needed to make select config options be marked as
   mutable. This change enables support for oslo provided config options
   to be updated via SIGHUP such as log level.

   Signed-off-by: song baisen <songbaisen@szzt.com.cn>
   Co-Authored-By: tangzhuo <ztang@hnu.edu.cn>, zhiyuan_cai <luckyvega.g@gmail.com>

Change-Id: I7b42bfb75913190fa4bd0d892e72fec8f629d7a6
songbaisen 5 years ago
parent e941bab3be
commit 912a4cb25e
  1. 3
  2. 3

@ -45,7 +45,8 @@ def serve(api_service, conf, workers=1):
if _launcher:
raise RuntimeError(_('serve() can only be called once'))
_launcher = service.launch(conf, api_service, workers=workers)
_launcher = service.ProcessLauncher(conf, restart_method='mutate')
_launcher.launch_service(api_service, workers=workers)
def wait():

@ -245,7 +245,8 @@ def serve(xservice, workers=1):
if _launcher:
raise RuntimeError(_('serve() can only be called once'))
_launcher = srv.launch(CONF, xservice, workers=workers)
_launcher = srv.ProcessLauncher(CONF, restart_method='mutate')
_launcher.launch_service(xservice, workers=workers)
def wait():