This is an automated email from the ASF dual-hosted git repository.
johnbodley pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/incubator-superset.git
The following commit(s) were added to refs/heads/master by this push:
new c6867d2 [init] Setting up cache before registering blueprints (#7992)
c6867d2 is described below
commit c6867d22b9a1174d635ddf746c2f8404c4648d95
Author: John Bodley <[email protected]>
AuthorDate: Tue Aug 6 14:45:39 2019 -0700
[init] Setting up cache before registering blueprints (#7992)
* [init] Setting up cache before registering blueprints
* Update __init__.py
---
superset/__init__.py | 7 ++++---
1 file changed, 4 insertions(+), 3 deletions(-)
diff --git a/superset/__init__.py b/superset/__init__.py
index d1981c0..12d8cf6 100644
--- a/superset/__init__.py
+++ b/superset/__init__.py
@@ -105,6 +105,10 @@ def get_manifest():
#################################################################
+# Setup the cache prior to registering the blueprints.
+cache = setup_cache(app, conf.get("CACHE_CONFIG"))
+tables_cache = setup_cache(app, conf.get("TABLE_NAMES_CACHE_CONFIG"))
+
for bp in conf.get("BLUEPRINTS"):
try:
print("Registering blueprint: '{}'".format(bp.name))
@@ -134,9 +138,6 @@ if conf.get("WTF_CSRF_ENABLED"):
pessimistic_connection_handling(db.engine)
-cache = setup_cache(app, conf.get("CACHE_CONFIG"))
-tables_cache = setup_cache(app, conf.get("TABLE_NAMES_CACHE_CONFIG"))
-
migrate = Migrate(app, db, directory=APP_DIR + "/migrations")
# Logging configuration