From a8f97920f927612f26aab0187f8fee3e3593686b Mon Sep 17 00:00:00 2001 From: tianfeng <769204422@qq.com> Date: Mon, 26 Jan 2026 11:16:00 +0800 Subject: [PATCH] =?UTF-8?q?=E6=9B=B4=E6=96=B0=E7=94=A8=E6=88=B7=E8=B5=84?= =?UTF-8?q?=E6=96=99=20=E5=88=A0=E9=99=A4cp=E6=95=B0=E6=8D=AE=E7=BC=93?= =?UTF-8?q?=E5=AD=98?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../other/app/command/user/UpdateUserProfileCmdExe.java | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/rc-service/rc-service-other/other-application/src/main/java/com/red/circle/other/app/command/user/UpdateUserProfileCmdExe.java b/rc-service/rc-service-other/other-application/src/main/java/com/red/circle/other/app/command/user/UpdateUserProfileCmdExe.java index 85939d6b..337faca1 100644 --- a/rc-service/rc-service-other/other-application/src/main/java/com/red/circle/other/app/command/user/UpdateUserProfileCmdExe.java +++ b/rc-service/rc-service-other/other-application/src/main/java/com/red/circle/other/app/command/user/UpdateUserProfileCmdExe.java @@ -15,6 +15,7 @@ import com.red.circle.other.domain.gateway.approval.ProfileApprovalGateway; import com.red.circle.other.domain.gateway.user.UserProfileGateway; import com.red.circle.other.domain.model.approval.ProfileApprovalContent; import com.red.circle.other.domain.model.user.UserProfile; +import com.red.circle.other.infra.database.cache.service.cp.CpRelationshipCacheService; import com.red.circle.other.infra.database.mongo.service.live.RoomProfileManagerService; import com.red.circle.other.infra.database.rds.entity.sys.SysCountryCode; import com.red.circle.other.infra.database.rds.entity.user.user.BaseInfo; @@ -28,6 +29,8 @@ import com.red.circle.other.inner.model.dto.user.PhotoItem; import com.red.circle.other.inner.asserts.user.UserErrorCode; import com.red.circle.other.inner.model.dto.user.UserProfileDTO; +import java.util.Arrays; +import java.util.Collections; import java.util.List; import java.util.Objects; import java.util.concurrent.TimeUnit; @@ -55,6 +58,7 @@ public class UpdateUserProfileCmdExe { private final ProfileApprovalGateway profileApprovalGateway; private final UserProfileAppConvertor userProfileAppConvertor; private final RoomProfileManagerService roomProfileManagerService; + private final CpRelationshipCacheService cpRelationshipCacheService; public UserProfileDTO execute(UserProfileModifyCmd cmd) { //敏感词 @@ -137,6 +141,9 @@ public class UpdateUserProfileCmdExe { // 更改国家 设置redis表示已修改 两年过期 redisService.setString("IS_UPDATE_COUNTRY:" + cmd.requiredReqUserId(), "1", 730, TimeUnit.DAYS); } + + cpRelationshipCacheService.remove(Collections.singletonList(cmd.requiredReqUserId())); + return userProfileAppConvertor.toUserProfileDTO(userProfile); }