You are viewing a plain text version of this content. The canonical link for it is here.
Posted to notifications@superset.apache.org by GitBox <gi...@apache.org> on 2022/03/01 22:22:00 UTC

[GitHub] [superset] ktmud commented on a change in pull request #18976: chore(cache): default to SimpleCache in debug mode

ktmud commented on a change in pull request #18976:
URL: https://github.com/apache/superset/pull/18976#discussion_r817189859



##########
File path: superset/config.py
##########
@@ -576,31 +578,44 @@ def _try_json_readsha(filepath: str, length: int) -> Optional[str]:
 # Setup image size default is (300, 200, True)
 # IMG_SIZE = (300, 200, True)
 
-# Default cache timeout, applies to all cache backends unless specifically overridden in
+
+# Default cache config, applies to all cache backends unless specifically overridden in
 # each cache config.
-CACHE_DEFAULT_TIMEOUT = int(timedelta(days=1).total_seconds())
+def DEFAULT_CACHE_CONFIG_FUNC(  # pylint: disable=invalid-name

Review comment:
       I'm not sure we need a whole function for this. How about simply setting `FILTER_STATE_CACHE_CONFIG` and `EXPLORE_FORM_DATA_CACHE_CONFIG` to `NullCache` and override it to `SimpleCache` or raise exception when app is starting (depending on whether `app.debug` is true)?




-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org
For additional commands, e-mail: notifications-help@superset.apache.org