forked from enyim/EnyimMemcached
-
Notifications
You must be signed in to change notification settings - Fork 50
Closed
Description
public async Task<IActionResult> Index()
{
_logger.LogDebug("Executing _memcachedClient.GetValueOrCreateAsync...");
var cacheSeconds = 2000;
var posts = await _memcachedClient.GetValueOrCreateAsync(
CacheKey,
cacheSeconds,
async () => await _blogPostService.GetRecent(10));
_logger.LogDebug("Done _memcachedClient.GetValueOrCreateAsync");
return Ok(posts);
}
测试的时候每次都会进入 await _blogPostService.GetRecent(10)); 这个子方法。
Metadata
Metadata
Assignees
Labels
No labels