Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

127 feat 인기 포트폴리오 방식 변경 #128

Open
wants to merge 9 commits into
base: develop
Choose a base branch
from

Conversation

kcsc2217
Copy link
Collaborator

@kcsc2217 kcsc2217 commented Jan 2, 2025

#️⃣연관된 이슈

ex) #이슈번호, #이슈번호

📝작업 내용

이번 PR에서 작업한 내용을 간략히 설명해주세요(이미지 첨부 가능)
일단 기존방식 zset을 사용하여 1시간 동안 가중치를 기록 후 zset에 저장

자세한 내용: https://velog.io/@kcsc2217/%EC%8B%A4%EC%8B%9C%EA%B0%84-%EC%9D%B8%EA%B8%B0-%ED%8F%AC%ED%8A%B8%ED%8F%B4%EB%A6%AC%EC%98%A4

스크린샷 (선택)

💬리뷰 요구사항(선택)

리뷰어가 특별히 봐주었으면 하는 부분이 있다면 작성해주세요

ex) 메서드 XXX의 이름을 더 잘 짓고 싶은데 혹시 좋은 명칭이 있을까요?

@kcsc2217 kcsc2217 linked an issue Jan 2, 2025 that may be closed by this pull request
2 tasks
@kcsc2217 kcsc2217 self-assigned this Jan 2, 2025
@kcsc2217 kcsc2217 added the 📌 feature New feature added label Jan 2, 2025
Copy link

github-actions bot commented Jan 2, 2025

Test Results

82 tests   82 ✅  17s ⏱️
16 suites   0 💤
16 files     0 ❌

Results for commit 7a05aec.

♻️ This comment has been updated with latest results.

Copy link
Collaborator

@AnTaeho AnTaeho left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

오늘중으로 나도 마무리 시키고 같이 서로 어떻게 구현했는지 공유하는 시간을 가지면 좋을 것 같습니다!

Comment on lines 143 to 145
redisKeys = redisKeys.stream()
.filter(redisKey -> !redisKey.contains("_user"))
.filter(redisKey -> !redisKey.contains("_user") && !redisKey.contains("_targets"))
.collect(Collectors.toSet());
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

나도 성능 체크를 해보긴 해야하는데
contains 보다 userTargetKey.split("_")[2].equals("targets");
이런식으로 구현하면 더 좋지 않을까 싶긴 함

}

/**
* 한식간 마다 로컬 캐시에 있는 가중치를 꺼내어 Zset에 반영
* 매 10분마다 가중치 반영
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

전체적으로 시간 단위가 통일되어 있지 않은 느낌이 있음.
이전 PR에서도 어떤건 6시간 3시간 적혀있고, 12시간 마다 동작하는거도 있고 등등 한번 정리가 필요할듯

Copy link

sonarqubecloud bot commented Jan 5, 2025

Quality Gate Failed Quality Gate failed

Failed conditions
67.9% Coverage on New Code (required ≥ 80%)
C Reliability Rating on New Code (required ≥ A)

See analysis details on SonarQube Cloud

Catch issues before they fail your Quality Gate with our IDE extension SonarQube for IDE

Copy link
Collaborator

@Leehunil Leehunil left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

궁금한 점은 말로 다 해결한 것 같아요! 상수 관리만 조금 해주면 머지해도 될 것 같습니다!!

@@ -187,12 +184,49 @@ public CustomSliceResponse findLikeList(
return gatheringRepository.PageFindLikeGathering(pageable, userId, likeId);
}

public List<GatheringPopularResponse> gatheringPopular(Optional<User> user){
String zSetKey = "gathering_Ranking";
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Const 이용해서 전역 변수로 처리하면 좋을 것 같아요!!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
📌 feature New feature added
Projects
None yet
Development

Successfully merging this pull request may close these issues.

[Feat] 인기 포트폴리오 방식 변경
3 participants