diff options
author | Erik Olof Gunnar Andersson <eandersson@blizzard.com> | 2017-05-22 15:05:34 -0700 |
---|---|---|
committer | Erik Olof Gunnar Andersson <eandersson@blizzard.com> | 2017-11-09 11:30:45 -0800 |
commit | fcf75dfd60f3d717f967a07f18ff186205c374e9 (patch) | |
tree | 34545a90cdbca83ffde9b9ca3b53012459a6dfbb /trove/db | |
parent | 6efc8465a8ff6621cdc97fbd257ca1716e7d9845 (diff) | |
download | trove-fcf75dfd60f3d717f967a07f18ff186205c374e9.tar.gz |
Lazy load all configuration options
This is a follow up to Change #444040.
Configuration options should always be lazy loaded,
this is to prevent changes in import order from
interfering with the configuration variable being
instantiated properly.
Change-Id: I3040108128ba56746ed4d5d688b8b8d33da753fc
Closes-Bug: #1694538
Diffstat (limited to 'trove/db')
-rw-r--r-- | trove/db/__init__.py | 4 |
1 files changed, 1 insertions, 3 deletions
diff --git a/trove/db/__init__.py b/trove/db/__init__.py index b8f27b3f..fc25ecee 100644 --- a/trove/db/__init__.py +++ b/trove/db/__init__.py @@ -20,11 +20,9 @@ from trove.common import utils CONF = cfg.CONF -db_api_opt = CONF.db_api_implementation - def get_db_api(): - return utils.import_module(db_api_opt) + return utils.import_module(CONF.db_api_implementation) class Query(object): |