Compare commits

...

64 Commits

Author SHA1 Message Date
ByungCheol 79fc8fea16 Merge branch 'dev'
Deploy / deploy (push) Failing after 13m49s
2026-07-02 01:47:29 +09:00
ByungCheol 190fbe835f perf(account): 내역 목록 태그 조회 N+1 → 배치 단일 쿼리로 개선
list() 에서 항목마다 findTagNamesByEntryId() 를 개별 호출하던 N+1 을
findTagsByEntryIds() 배치 쿼리 1회로 대체.
항목 수가 많을 때 타임아웃/과부하 방지.

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-07-02 01:47:08 +09:00
ByungCheol 3ceb3c4253 Merge branch 'dev'
Deploy / deploy (push) Failing after 13m44s
2026-07-02 00:45:44 +09:00
ByungCheol 186aec7bb4 Merge branch 'dev'
Deploy / deploy (push) Failing after 13m59s
2026-06-30 22:35:35 +09:00
ByungCheol 3535c2e220 Merge branch 'dev'
Deploy / deploy (push) Failing after 12m21s
2026-06-30 21:37:07 +09:00
ByungCheol 204c5ce430 Merge branch 'dev'
Deploy / deploy (push) Failing after 13m50s
2026-06-28 18:25:50 +09:00
ByungCheol 706deb057e Merge branch 'dev'
Deploy / deploy (push) Successful in 53s
2026-06-28 18:16:58 +09:00
ByungCheol e5d1b5d40c Merge branch 'dev'
Deploy / deploy (push) Failing after 14m27s
2026-06-28 18:05:13 +09:00
ByungCheol d028d957b6 Merge branch 'dev'
Deploy / deploy (push) Failing after 15m25s
2026-06-28 17:29:17 +09:00
ByungCheol f28ecd853e Merge branch 'dev'
Deploy / deploy (push) Failing after 13m16s
2026-06-28 16:56:25 +09:00
ByungCheol 5fec464f90 Merge branch 'dev'
Deploy / deploy (push) Failing after 15m19s
2026-06-28 16:04:22 +09:00
ByungCheol 483aaa6473 Merge branch 'dev'
Deploy / deploy (push) Failing after 15m15s
2026-06-28 15:44:26 +09:00
ByungCheol 5bd2616de9 Merge branch 'dev'
Deploy / deploy (push) Failing after 15m28s
2026-06-28 15:24:13 +09:00
ByungCheol ad40af18b2 Merge branch 'dev'
Deploy / deploy (push) Failing after 11m55s
2026-06-28 15:12:47 +09:00
ByungCheol 95d84c8138 Merge branch 'dev'
Deploy / deploy (push) Failing after 15m14s
2026-06-28 14:44:25 +09:00
ByungCheol 08338d516f Merge branch 'dev'
Deploy / deploy (push) Failing after 14m43s
2026-06-28 14:05:01 +09:00
ByungCheol dc4e99a6db Merge branch 'dev'
Deploy / deploy (push) Failing after 15m22s
2026-06-28 13:34:21 +09:00
ByungCheol f408715e17 Merge branch 'dev'
Deploy / deploy (push) Failing after 13m19s
2026-06-28 13:21:21 +09:00
ByungCheol 74a2cae9ef Merge branch 'dev'
Deploy / deploy (push) Failing after 15m11s
2026-06-28 12:29:27 +09:00
ByungCheol 6e269888c2 Merge branch 'dev'
Deploy / deploy (push) Failing after 11m49s
2026-06-28 11:07:51 +09:00
ByungCheol 39a11d299c Merge branch 'dev'
Deploy / deploy (push) Failing after 11m53s
2026-06-28 09:22:46 +09:00
ByungCheol f19f653715 Merge branch 'dev'
Deploy / deploy (push) Failing after 13m31s
CI / build (push) Failing after 15m20s
2026-06-28 09:04:22 +09:00
ByungCheol 16ddf88de3 Merge branch 'dev'
Deploy / deploy (push) Failing after 14m0s
CI / build (push) Failing after 15m50s
2026-06-28 08:38:52 +09:00
ByungCheol d794549f66 Merge branch 'dev'
Deploy / deploy (push) Failing after 12m43s
CI / build (push) Failing after 14m31s
2026-06-27 23:00:14 +09:00
ByungCheol 0e26237577 Merge branch 'dev'
CI / build (push) Failing after 12m28s
Deploy / deploy (push) Failing after 15m38s
2026-06-27 22:27:13 +09:00
ByungCheol 1646ec0a7f Merge branch 'dev'
Deploy / deploy (push) Failing after 11m22s
CI / build (push) Failing after 13m9s
2026-06-27 19:02:12 +09:00
ByungCheol fe0837cfd6 Merge branch 'dev'
Deploy / deploy (push) Successful in 50s
CI / build (push) Failing after 12m12s
2026-06-27 18:03:44 +09:00
ByungCheol 68f6c985bc Merge branch 'dev'
Deploy / deploy (push) Failing after 12m4s
CI / build (push) Failing after 14m3s
2026-06-27 14:47:00 +09:00
ByungCheol 47a01356a5 Merge branch 'dev'
CI / build (push) Failing after 12m36s
Deploy / deploy (push) Failing after 15m41s
2026-06-24 23:03:38 +09:00
ByungCheol 236332637a Merge branch 'dev'
Deploy / deploy (push) Failing after 13m31s
CI / build (push) Failing after 15m21s
2026-06-22 23:16:03 +09:00
ByungCheol 0e71e7b8cc Merge branch 'dev'
Deploy / deploy (push) Failing after 11m25s
CI / build (push) Failing after 13m19s
2026-06-22 22:38:06 +09:00
ByungCheol 9d4a415f2e Merge branch 'dev'
Deploy / deploy (push) Successful in 51s
CI / build (push) Failing after 12m48s
2026-06-20 17:13:14 +09:00
ByungCheol 5230ba1587 Merge branch 'dev'
Deploy / deploy (push) Failing after 11m6s
CI / build (push) Failing after 13m0s
2026-06-14 15:43:30 +09:00
ByungCheol 1f8b968588 Merge branch 'dev'
Deploy / deploy (push) Failing after 11m55s
CI / build (push) Failing after 13m43s
2026-06-12 22:52:23 +09:00
ByungCheol b90f9ea3b8 Merge branch 'dev'
Deploy / deploy (push) Failing after 11m21s
CI / build (push) Failing after 13m9s
2026-06-12 22:22:59 +09:00
ByungCheol a61700bdf6 Merge branch 'dev'
Deploy / deploy (push) Failing after 13m5s
CI / build (push) Failing after 14m58s
2026-06-12 22:16:09 +09:00
ByungCheol 484732c5ed Merge branch 'dev'
Deploy / deploy (push) Failing after 11m54s
CI / build (push) Failing after 13m49s
2026-06-09 22:47:32 +09:00
ByungCheol e3a24848bc Merge branch 'dev'
Deploy / deploy (push) Failing after 12m3s
CI / build (push) Failing after 13m52s
2026-06-07 20:32:38 +09:00
ByungCheol fd25968d0e Merge branch 'dev'
Deploy / deploy (push) Failing after 12m12s
CI / build (push) Failing after 14m4s
2026-06-07 19:17:25 +09:00
ByungCheol c61cec6dad Merge branch 'dev'
Deploy / deploy (push) Failing after 11m5s
CI / build (push) Failing after 12m55s
2026-06-06 17:33:33 +09:00
ByungCheol 2eef5c3b3e Merge branch 'dev'
Deploy / deploy (push) Failing after 11m56s
CI / build (push) Failing after 13m46s
2026-06-06 16:42:34 +09:00
ByungCheol 4f8ade5ff3 Merge branch 'dev'
CI / build (push) Failing after 12m27s
Deploy / deploy (push) Failing after 15m41s
2026-06-06 15:03:53 +09:00
ByungCheol 8bfe596f4e Merge branch 'dev'
CI / build (push) Failing after 11m31s
Deploy / deploy (push) Failing after 14m44s
2026-06-06 14:49:48 +09:00
ByungCheol 76bbf195df Merge branch 'dev'
Deploy / deploy (push) Failing after 12m0s
CI / build (push) Failing after 13m45s
2026-06-06 14:27:33 +09:00
ByungCheol b62b51b789 Merge branch 'dev'
Deploy / deploy (push) Failing after 12m22s
CI / build (push) Failing after 14m11s
2026-06-06 14:14:15 +09:00
ByungCheol 91cc5558e4 Merge branch 'dev'
Deploy / deploy (push) Failing after 11m20s
CI / build (push) Failing after 13m8s
2026-06-06 14:08:13 +09:00
ByungCheol 27b8829def Merge branch 'dev'
Deploy / deploy (push) Failing after 11m29s
CI / build (push) Failing after 13m15s
2026-06-06 08:13:03 +09:00
ByungCheol ad2ee4e75d Merge branch 'dev'
Deploy / deploy (push) Failing after 13m1s
CI / build (push) Failing after 14m52s
2026-06-06 00:16:30 +09:00
ByungCheol eb24a315d3 Merge branch 'dev'
CI / build (push) Failing after 11m1s
Deploy / deploy (push) Failing after 14m15s
2026-06-04 05:00:27 +09:00
ByungCheol 396e986792 Merge branch 'dev'
Deploy / deploy (push) Failing after 11m21s
CI / build (push) Failing after 13m3s
2026-06-03 18:51:32 +09:00
ByungCheol 191f1cfbe4 Merge branch 'dev'
CI / build (push) Failing after 12m15s
Deploy / deploy (push) Failing after 15m32s
2026-06-03 17:37:20 +09:00
ByungCheol 1d4dbc2183 Merge branch 'dev'
CI / build (push) Failing after 12m10s
Deploy / deploy (push) Failing after 15m27s
2026-06-03 16:42:22 +09:00
ByungCheol 478a75b6d8 Merge branch 'dev' into main
Deploy / deploy (push) Failing after 13m38s
CI / build (push) Failing after 15m20s
2026-06-01 22:54:25 +09:00
ByungCheol 41a5780e14 Merge branch 'dev' into main
CI / build (push) Successful in 50s
Deploy / deploy (push) Failing after 15m16s
2026-06-01 22:37:43 +09:00
ByungCheol 86c56f6c6f Merge branch 'dev' into main
Deploy / deploy (push) Failing after 11m36s
CI / build (push) Failing after 13m18s
2026-05-31 21:46:30 +09:00
ByungCheol bd1164866c Merge branch 'dev' into main
Deploy / deploy (push) Failing after 13m16s
CI / build (push) Failing after 14m57s
2026-05-31 20:49:52 +09:00
ByungCheol f884cb7b06 Merge branch 'dev' into main
CI / build (push) Failing after 11m54s
Deploy / deploy (push) Failing after 15m13s
2026-05-31 19:12:56 +09:00
ByungCheol e5fd31843a Merge branch 'dev' into main
Deploy / deploy (push) Failing after 11m27s
CI / build (push) Failing after 13m7s
2026-05-31 19:01:43 +09:00
ByungCheol a821cd8f89 Merge branch 'dev' into main
Deploy / deploy (push) Failing after 11m24s
CI / build (push) Failing after 13m6s
2026-05-31 18:46:44 +09:00
ByungCheol cf275fabf6 Merge branch 'dev' into main
CI / build (push) Failing after 11m53s
Deploy / deploy (push) Failing after 15m12s
2026-05-31 18:22:53 +09:00
ByungCheol d373e3e9e4 Merge branch 'dev' into main
Deploy / deploy (push) Has been cancelled
CI / build (push) Has been cancelled
fix(ci): SSH 개인키 CR 제거
2026-05-31 17:40:10 +09:00
ByungCheol f79c2412fd Merge branch 'dev' into main
Deploy / deploy (push) Has been cancelled
CI / build (push) Has been cancelled
ci: 자동 배포 워크플로 + 서버 설정 파일
2026-05-31 15:55:35 +09:00
ByungCheol f3230dcc5b Merge branch 'dev' into main
CI / build (push) Failing after 12m12s
ci: Gitea Actions CI/CD 워크플로 추가
2026-05-31 15:49:08 +09:00
ByungCheol ef7d0f7f83 Merge branch 'dev' into main
가계부·게시판 백엔드 API 구현 (account/auth/board/user/admin)
2026-05-31 15:45:25 +09:00
3 changed files with 28 additions and 3 deletions
@@ -93,4 +93,7 @@ public interface AccountEntryMapper {
int deleteEntryTagsByEntryId(@Param("entryId") Long entryId); int deleteEntryTagsByEntryId(@Param("entryId") Long entryId);
List<String> findTagNamesByEntryId(@Param("entryId") Long entryId); List<String> findTagNamesByEntryId(@Param("entryId") Long entryId);
/** 복수 항목의 태그를 한 번에 조회 — {entryId, tagName} 맵 반환 */
List<Map<String, Object>> findTagsByEntryIds(@Param("entryIds") List<Long> entryIds);
} }
@@ -53,9 +53,19 @@ public class AccountService {
public List<AccountEntryResponse> list(Long memberId, Integer year, Integer month, public List<AccountEntryResponse> list(Long memberId, Integer year, Integer month,
String type, String category, Long walletId, String keyword, Long tagId) { String type, String category, Long walletId, String keyword, Long tagId) {
return mapper.findByMember(memberId, year, month, List<AccountEntry> entries = mapper.findByMember(memberId, year, month,
blankToNull(type), blankToNull(category), walletId, blankToNull(keyword), tagId).stream() blankToNull(type), blankToNull(category), walletId, blankToNull(keyword), tagId);
.map(this::toResponse) if (entries.isEmpty()) return List.of();
// 태그 N+1 방지: 한 번에 모든 entry 의 태그를 조회 후 Map 으로 그룹화
List<Long> ids = entries.stream().map(AccountEntry::getId).toList();
Map<Long, List<String>> tagsByEntry = new HashMap<>();
for (Map<String, Object> row : mapper.findTagsByEntryIds(ids)) {
Long eid = ((Number) row.get("entryId")).longValue();
String name = (String) row.get("tagName");
tagsByEntry.computeIfAbsent(eid, k -> new ArrayList<>()).add(name);
}
return entries.stream()
.map(e -> AccountEntryResponse.from(e, tagsByEntry.getOrDefault(e.getId(), List.of())))
.toList(); .toList();
} }
@@ -234,4 +234,16 @@
ORDER BY t.name ORDER BY t.name
</select> </select>
<!-- 복수 항목의 태그를 한 번에 조회 — {entry_id, tag_name} 행 반환 -->
<select id="findTagsByEntryIds" resultType="map">
SELECT aet.entry_id AS entryId, t.name AS tagName
FROM account_tag t
JOIN account_entry_tag aet ON aet.tag_id = t.id
WHERE aet.entry_id IN
<foreach item="id" collection="entryIds" open="(" separator="," close=")">
#{id}
</foreach>
ORDER BY aet.entry_id, t.name
</select>
</mapper> </mapper>