From b92dadb1b1547160cfeb5737d7637317aacf63e8 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Herv=C3=A9=20Beraud?= Date: Thu, 4 Jun 2020 11:01:40 +0200 Subject: [PATCH] Always reset CONF when starting the wsgi app This ensures that options loaded during any prior run of the application are dropped before being added again during init_application. Change-Id: I599b4b301d1eb8c5824f378dfd7fdcf8145d11aa --- cyborg/api/wsgi_app.py | 3 +++ 1 file changed, 3 insertions(+) diff --git a/cyborg/api/wsgi_app.py b/cyborg/api/wsgi_app.py index 0baa8dfb..115fda8f 100644 --- a/cyborg/api/wsgi_app.py +++ b/cyborg/api/wsgi_app.py @@ -31,6 +31,9 @@ from cyborg.common import service def init_application(): CONF = cfg.CONF + # NOTE(hberaud): Call reset to ensure the ConfigOpts object doesn't + # already contain registered options if the app is reloaded. + CONF.reset() i18n.install('cyborg')