Commit a695f815 authored by 刘基明's avatar 刘基明

添加注释

parent 84cbe4c3
...@@ -483,7 +483,7 @@ public class ThemeManager { ...@@ -483,7 +483,7 @@ public class ThemeManager {
// 评论列表 // 评论列表
List<CommentEntity> commentEntities = commentService.queryCommentsByUserId(req.getUserId(), req.getLastId(), req.getPageSize()); List<CommentEntity> commentEntities = commentService.queryCommentsByUserId(req.getUserId(), req.getLastId(), req.getPageSize());
// 当前用户信息 // 当前用户信息
UserInfoNew userInfo = redisCache.getObject(StringUtils.joinWith(CACHE_FEIGN_USER_INFO, req.getUserId()), UserInfoNew userInfo = redisCache.getObject(StringUtils.joinWith("_", CACHE_FEIGN_USER_INFO, req.getUserId()),
60, () -> this.getUserInfo(req.getUserId()), UserInfoNew.class); 60, () -> this.getUserInfo(req.getUserId()), UserInfoNew.class);
Set<String> replyThemeIds = commentEntities.stream().map(CommentEntity::getThemeId).collect(Collectors.toSet()); Set<String> replyThemeIds = commentEntities.stream().map(CommentEntity::getThemeId).collect(Collectors.toSet());
if (CollectionUtils.isEmpty(replyThemeIds)) { if (CollectionUtils.isEmpty(replyThemeIds)) {
......
...@@ -78,7 +78,7 @@ public class RankService { ...@@ -78,7 +78,7 @@ public class RankService {
theme.setViewCount(visitCountMap.getOrDefault(themeId,0)); theme.setViewCount(visitCountMap.getOrDefault(themeId,0));
//查询用户质量 //查询用户质量
String authorId = theme.getAuthorId(); String authorId = theme.getAuthorId();
UserInfoNew authorInfo = redisCache.getObject(StringUtils.joinWith(CACHE_FEIGN_USER_INFO, authorId), UserInfoNew authorInfo = redisCache.getObject(StringUtils.joinWith("_", CACHE_FEIGN_USER_INFO, authorId),
60, () -> feignService.getUserInfoById(authorId), UserInfoNew.class); 60, () -> feignService.getUserInfoById(authorId), UserInfoNew.class);
if (authorInfo == null || authorInfo.getLevelGrade() == null) { if (authorInfo == null || authorInfo.getLevelGrade() == null) {
theme.setUserWeight(0.0); theme.setUserWeight(0.0);
......
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