diff --git a/lib/middleware/cache.js b/lib/middleware/cache.js index f69275ade..7b332ffe2 100644 --- a/lib/middleware/cache.js +++ b/lib/middleware/cache.js @@ -144,6 +144,7 @@ module.exports = function(app, options = {}) { let type; let ok = false; + logger.warn(`getCache in ${key} ${value}`); if (value) { ctx.response.status = 200; type = (await globalCache.get(tkey)) || 'text/html'; @@ -243,6 +244,7 @@ module.exports = function(app, options = {}) { try { ok = await getCache(ctx, key, tkey); } catch (e) { + logger.warn(`getCache catch ${e instanceof Error ? e.stack : e}`); ok = false; } if (ok) {