Skip to content

Commit 3dc642c

Browse files
committed
[FIX]: Laz InitializationException 해결 - FETCH JOIN 적용
1 parent 765e628 commit 3dc642c

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

back/src/main/java/com/back/domain/scenario/service/ScenarioService.java

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -230,8 +230,8 @@ private void ensureSameLine(DecisionLine line, DecisionNodeNextRequest lastDecis
230230
throw new ApiException(ErrorCode.INVALID_INPUT_VALUE, "lastDecision.parentDecisionNodeId is required");
231231
}
232232

233-
// 부모 노드 id로 조회(없으면 404)
234-
DecisionNode parent = decisionNodeRepository.findById(lastDecision.parentDecisionNodeId())
233+
// 부모 노드 id로 조회(없으면 404) - DecisionLine과 User를 EAGER 로딩
234+
DecisionNode parent = decisionNodeRepository.findWithLineAndUserById(lastDecision.parentDecisionNodeId())
235235
.orElseThrow(() -> new ApiException(
236236
ErrorCode.NODE_NOT_FOUND,
237237
"parent decision node not found: " + lastDecision.parentDecisionNodeId()

0 commit comments

Comments
 (0)