fix(session): generate.followup listener를 REQUIRES_NEW 로 (LazyInitial…#35
Merged
Conversation
…izationException) @TransactionalEventListener + NOT_SUPPORTED 조합에서 messageRepository.findById() 가 자체 짧은 트랜잭션을 열고 닫은 뒤 parent.getSession() (InterviewSession LAZY 프록시) 접근 시점에 세션이 없어 LazyInitializationException 발생. REQUIRES_NEW 로 listener 전체를 새 트랜잭션에 묶어 LAZY 로딩 가능하게. Spring 7 의 "AFTER_COMMIT listener 에 @transactional 사용 시 NOT_SUPPORTED 또는 REQUIRES_NEW 만 허용" 제약도 만족. 원인: stack-up.shop 골든패스 E2E 점검 중 답변 제출 후 followup 미발행으로 발견.
|
The latest updates on your projects. Learn more about Vercel for GitHub.
|
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
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.
…izationException)
@TransactionalEventListener + NOT_SUPPORTED 조합에서 messageRepository.findById() 가 자체 짧은 트랜잭션을 열고 닫은 뒤 parent.getSession() (InterviewSession LAZY 프록시) 접근 시점에 세션이 없어 LazyInitializationException 발생.
REQUIRES_NEW 로 listener 전체를 새 트랜잭션에 묶어 LAZY 로딩 가능하게. Spring 7 의 "AFTER_COMMIT listener 에 @transactional 사용 시 NOT_SUPPORTED 또는 REQUIRES_NEW 만 허용" 제약도 만족.
원인: stack-up.shop 골든패스 E2E 점검 중 답변 제출 후 followup 미발행으로 발견.