Commit 9296eb65 authored by 刘基明's avatar 刘基明

降低缓存刷新频率

parent 5609bb9d
......@@ -30,7 +30,7 @@ public class ConJobManager {
/**
* 定时统计 话题 访问数据,并刷到redis
*/
@Scheduled(cron = "*/10 * * * * ?")
// @Scheduled(cron = "*/10 * * * * ?")
public void topicVisitorStats() {
String topicId = "123";
Integer detailVisitTimes = visitLogService.queryTopicDetailVisit(topicId);
......@@ -40,16 +40,16 @@ public class ConJobManager {
/**
* 定时统计主题、话题排行
*/
@Scheduled(cron = "*/30 * * * * ?")
@Scheduled(cron = "10 */2 * * * ?")
public void themeRank() {
rankService.rankThemes();
rankService.rankTopics();
}
/**
* 定时统计主题、话题排行
* 定时刷新最新帖子
*/
@Scheduled(cron = "*/5 * * * * ?")
@Scheduled(cron = "*/10 * * * * ?")
public void getThemeNewest() {
recommendService.refreshNewestThemes();
}
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment