def make_cache():
timeout = app.config['CACHE_TIMEOUT']
if app.config['MEMCACHED_ENABLED']:
hosts = app.config['MEMCACHED_HOSTS']
return BinarySupportedMemcachedCache(hosts, default_timeout=timeout)
return SimpleCache(default_timeout=timeout)
评论列表
文章目录