I know this is not an issue and doesn't concern with this library. I am trying to refresh cache from an API like the below method:
function refreshCache(req, res, next) {
appCache.flushAll();
res.status(200).send('Cache cleared');
}
The flush event below is called; however I would like to send the response after the tasks are done but no way to find the response object here:
appCache.on("flush", function () {
reloadCache(); // <-- This is some promise and i want to send response after that.
log.console.info('App Cache: flushed. Going to reload cache');
});