[Fix] 컬렉션 권한 캐시 N+1 제거 및 @Modifying 안전성 보완 - #20
Conversation
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
컬렉션 권한 N+1 해결을 위한 @Modifying 벌크 UPDATE/SELECT 쿼리 추가 - bulkInvalidateBySource: sourceType+sourceId 기준 일괄 invalidate - bulkUpdateBySource: sourceType+sourceId 기준 일괄 갱신 - findDocumentIdsByUserIdAndSourceTypeAndSourceId: 기캐시 문서 ID 조회 Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
컬렉션 권한 N+1 해결을 위한 bulk grant/revoke 메서드 추가 - bulkGrantUserPermission: 일괄 UPDATE 후 누락분만 saveAll 배치 INSERT - bulkRevokeBySource: 단일 @Modifying UPDATE로 전체 무효화 Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
컬렉션 권한 부여/회수 시 루프 기반 캐시 처리를 벌크 메서드로 교체 - revokePermission: 문서 목록 조회 루프 → bulkRevokeBySource 단일 쿼리 - updateCacheForCollection: 개별 grantUserPermission → bulkGrantUserPermission Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
벌크 UPDATE 후 같은 트랜잭션에서 1차 캐시(영속성 컨텍스트)와 DB 값이 어긋나는 문제를 방지 Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
|
Warning Review limit reached
Next review available in: 21 minutes Enable usage-based reviews in Billing to review now. Otherwise, wait until the next included review is available. How can I continue?After more reviews become available, a review can be triggered using the To avoid repeated limits, reduce automatic review volume by pausing incremental auto-reviews earlier, using label-based review opt-in, excluding WIP or generated PR titles, or requesting reviews manually when the PR is ready. If your team needs uninterrupted high-volume reviews, an organization admin can enable usage-based reviews. How do review limits work?CodeRabbit enforces per-developer PR review limits for each organization. Most developers receive the normal plan review availability. For paid Pro and Pro+ PR reviews, CodeRabbit uses adaptive limits for sustained high-volume activity. When a developer's recent PR review activity reaches the 95th percentile or higher among CodeRabbit users, additional reviews become available more gradually as earlier reviews age out of the rolling window. Please refer docs for additional details. Review details⚙️ Run configurationConfiguration used: Path: .coderabbit.yaml Review profile: CHILL Plan: Pro Plus Run ID: 📒 Files selected for processing (4)
✨ Finishing Touches🧪 Generate unit tests (beta)
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
🔍 작업 내용
CodeRabbit 리뷰 반영 — 이전 PR(#19) 머지 이후 추가된 성능 개선
✨ 상세 설명
bulkRevokeBySource단일 UPDATE (201번 → 1번)bulkUpdateBySource+saveAll배치 (201번 → 3번)@Modifying 안전성
clearAutomatically = true추가 — 벌크 UPDATE 후 1차 캐시와 DB 불일치 방지💬 리뷰 요구사항
bulkGrantUserPermission흐름 (UPDATE → 누락 ID 조회 → saveAll) 확인 부탁