Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Sign in
Toggle navigation
T
tanpu-community
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Packages
Packages
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
探普后端
tanpu-community
Commits
1bc324ab
Commit
1bc324ab
authored
Aug 04, 2021
by
刘基明
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
转发后删除原贴fix
parent
073385d6
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
3 additions
and
3 deletions
+3
-3
RedisKeyConstant.java
...a/com/tanpu/community/api/constants/RedisKeyConstant.java
+1
-1
ThemeManager.java
...c/main/java/com/tanpu/community/manager/ThemeManager.java
+2
-2
No files found.
community-api/src/main/java/com/tanpu/community/api/constants/RedisKeyConstant.java
View file @
1bc324ab
...
@@ -18,7 +18,7 @@ public class RedisKeyConstant {
...
@@ -18,7 +18,7 @@ public class RedisKeyConstant {
// 主题本身
// 主题本身
public
static
final
String
CACHE_THEME_ID
=
"CACHE_THEME_ID_"
;
public
static
final
String
CACHE_THEME_ID
=
"CACHE_THEME_ID_"
;
// 转发主题本身
// 转发主题本身
public
static
final
String
CACHE_FOR
MER_THEME_ID
=
"CACHE_FORMER
_THEME_ID_"
;
public
static
final
String
CACHE_FOR
WARD_THEME_ID
=
"CACHE_FORWARD
_THEME_ID_"
;
// 关注的人,上次浏览的最新主题last id
// 关注的人,上次浏览的最新主题last id
public
static
final
String
CACHE_IDOL_THEME_LAST_ID
=
"CACHE_IDOL_THEME_LAST_ID_"
;
public
static
final
String
CACHE_IDOL_THEME_LAST_ID
=
"CACHE_IDOL_THEME_LAST_ID_"
;
...
...
community-service/src/main/java/com/tanpu/community/manager/ThemeManager.java
View file @
1bc324ab
...
@@ -347,7 +347,7 @@ public class ThemeManager {
...
@@ -347,7 +347,7 @@ public class ThemeManager {
private
void
buildThemeQoExtraInfo
(
ThemeQo
themeQo
)
{
private
void
buildThemeQoExtraInfo
(
ThemeQo
themeQo
)
{
String
themeId
=
themeQo
.
getThemeId
();
String
themeId
=
themeQo
.
getThemeId
();
// 封装转发对象
// 封装转发对象
FormerThemeQo
former
=
redisCache
.
getObject
(
StringUtils
.
joinWith
(
"_"
,
CACHE_FOR
MER_THEME_ID
,
themeId
),
60
,
FormerThemeQo
former
=
redisCache
.
getObject
(
StringUtils
.
joinWith
(
"_"
,
CACHE_FOR
WARD_THEME_ID
,
themeQo
.
getFormerThemeId
()
),
60
,
()
->
this
.
getFormerTheme
(
themeQo
.
getFormerThemeId
()),
FormerThemeQo
.
class
);
()
->
this
.
getFormerTheme
(
themeQo
.
getFormerThemeId
()),
FormerThemeQo
.
class
);
themeQo
.
setFormerTheme
(
former
);
themeQo
.
setFormerTheme
(
former
);
...
@@ -690,7 +690,7 @@ public class ThemeManager {
...
@@ -690,7 +690,7 @@ public class ThemeManager {
}
}
private
void
evictThemeCache
(
String
themeId
){
private
void
evictThemeCache
(
String
themeId
){
redisCache
.
evict
(
StringUtils
.
joinWith
(
"_"
,
CACHE_FOR
MER
_THEME_ID
,
themeId
));
redisCache
.
evict
(
StringUtils
.
joinWith
(
"_"
,
CACHE_FOR
WARD
_THEME_ID
,
themeId
));
redisCache
.
evict
(
StringUtils
.
joinWith
(
"_"
,
CACHE_THEME_ID
,
themeId
));
redisCache
.
evict
(
StringUtils
.
joinWith
(
"_"
,
CACHE_THEME_ID
,
themeId
));
}
}
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment