@EntityGraph(attributePaths = {"responseEntitySet","responseEntitySet.questionOptionEntity","fileEntitySet"})
Page<UserEntity> findAllByRole(Pageable pageable, UserRole role);
-->
spring.jpa.show-sql=true
spring.jpa.properties.hibernate.format_sql=true
시 조회 가능
@EntityGraph 어노테이션 제거
Page<UserEntity> findAllByRole(Pageable pageable, UserRole role);
-> limit 절이 적용되었지만,
@BatchSize 어노테이션 적용
@OneToMany(cascade = CascadeType.ALL)
@JoinColumn(name="user_id")
@BatchSize(size=100)
private Set<ResponseEntity> responseEntitySet = new LinkedHashSet<>();
@OneToMany(cascade = CascadeType.ALL)
@JoinColumn(name="user_id")
@BatchSize(size=100)
private Set<FileEntity> fileEntitySet = new LinkedHashSet<>();