feat(relation): 实现用户取关功能

- 新增取消关注接口及完整业务逻辑
- 添加 Lua 脚本支持 Redis 取关校验与删除操作
- 实现 MQ 异步处理取关事件
- 补充相关 DTO、VO 类以及枚举响应码
- 完善 Redis Key 构建工具方法
- 增加 HTTP 测试用例用于手动验证接口
- 优化关注流程中的 Redis ZSet 粉丝列表维护逻辑
- 添加粉丝数量限制控制,超出时自动移除最早关注者
This commit is contained in:
2025-10-13 22:40:11 +08:00
parent f0afb23a73
commit b70d9073d8
12 changed files with 300 additions and 5 deletions

View File

@@ -145,4 +145,13 @@ Authorization: Bearer {{token}}
{
"followUserId": {{otherUserId}}
}
### 取消关注
POST http://localhost:8000/relation/relation/unfollow
Content-Type: application/json
Authorization: Bearer {{token}}
{
"unfollowUserId": 2100
}