Skip to content

Commit

Permalink
[TDC-93] StickerCount 동시성 이슈 대응
Browse files Browse the repository at this point in the history
  • Loading branch information
yerimkoko committed May 18, 2024
1 parent 1530e5e commit afebb1f
Show file tree
Hide file tree
Showing 3 changed files with 10 additions and 10 deletions.
12 changes: 4 additions & 8 deletions threedollar-application/http/sticker.http
Original file line number Diff line number Diff line change
Expand Up @@ -4,20 +4,16 @@ X-Community-Api-Key: {{api_key}}
Content-Type: application/json

{
"targetId": "5",
"accountId": "2",
"stickerNames": ["DISLIKE"]
"targetId": "1481",
"accountId": "USER_ACCOUNT:478",
"stickerNames": ["LIKE"]
}

### 스티커를 제거합니다
DELETE {{host_api}}/community/v1/sticker-group/REVIEW/stickers
DELETE {{host_api}}/community/v1/sticker-group/REVIEW/stickers?targetId=1481&accountId=USER_ACCOUNT:478
X-Community-Api-Key: {{api_key}}
Content_Type: application/json

{
"targetId": "5"
}


### 타겟들에 대한 스티커를 조회합니다
GET {{host_api}}/community/v1/sticker-group/REVIEW/stickers?targetIds=4,5,22&accountId=100
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@ public class StickerInfoDetail {
@Builder
public StickerInfoDetail(String stickerName, Long stickerCount, String imageUrl, boolean selectedByMe) {
this.stickerName = stickerName;
this.stickerCount = stickerCount;
this.stickerCount = Math.min(stickerCount, 0);
this.imageUrl = imageUrl;
this.selectedByMe = selectedByMe;
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -59,7 +59,11 @@ public StickerAction(@NotNull StickerGroup stickerGroup,
this.targetId = targetId;
}

public static StickerAction newInstance(StickerGroup stickerGroup, String workspaceId, Set<Long> stickerIds, String accountId, String targetId) {
public static StickerAction newInstance(StickerGroup stickerGroup,
String workspaceId,
Set<Long> stickerIds,
String accountId,
String targetId) {
return StickerAction.builder()
.stickerGroup(stickerGroup)
.workspaceId(workspaceId)
Expand Down

0 comments on commit afebb1f

Please sign in to comment.