feat: Spring Batch 기반 TripReport 연관 엔티티 삭제 및 하드 딜리트 기능 추가(#92) #94
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
📌 작업 내용 및 특이사항
✅ TripReport, TripReportStudyLog 연관 엔티티 삭제 및 하드 딜리트 기능 추가
TripReportQueryRepository.deleteAllByDeletedMemberOwner()를 통해 삭제된 멤버가 소유한 여행 리포트 삭제TripReportStudyLogQueryRepository.deleteAllByDeletedMemberOwner()를 통해 삭제된 멤버가 소유한 여행 리포트 또는 학습 로그가 존재하면, 연관된 TripReportStudy 삭제TripReportCommandService,TripReportStudyLogCommandService에 하드 딜리트 비즈니스 로직 추가✅ HardDeleteFacade에 TripReport, TripReportStudyLog에 하드 딜리트 비즈니스 로직 추가
BatchJobScheduler를 통해 매일 04시에 하드 딜리트 삭제 처리 진행HardDeleteExecutor를 통해 배치 처리 로그 기록 작성✅ 테스트
TripReportCommandServiceTest에HardDeleteTripReportsOwnedByDeletedMember단위 테스트 추가TripReportStudyLogCommandServiceTest에HardDeleteTripReportStudyLogsOwnedByDeletedMember단위 테스트 추가🌱 관련 이슈
🔍 참고사항(선택)
updateDeletedAt()이 없기 때문에, 삭제된 멤버를 기준으로TripReportStudyLog를 삭제하는 비즈니스 로직을 구현했습니다.📚 기타(선택)