로딩
요청 처리 중입니다...

[JPA] 실전! 스프링 데이터 JPA Part5. 스프링 데이터 JPA 분석 / Part6. 나머지 기능들

 [JPA] 실전! 스프링 데이터 JPA Part5. 스프링 데이터 JPA 분석 / Part6. 나머지 기능들

1.스프링 데이터 JPA 구현체 분석 - 스프링 데이터 JPA가 제공하는 공통 인터페이스의 구현체 - org.springframework.data.jpa.repository.support.SimpleJpaRepository @Repository @Transactional(readOnly = true) public class SimpleJpaRepository ...{ @Transactional public S save(S entity) { if (entityInformation.isNew(entity)) { em.persist(entity); return entity; } else { return em.merge(entity); } } ... } - @Repository 적용 : JPA 예외를 스프링이 추상화한 예외로 변환 - @Transactional 트랜잭션 적용 : 1) JPA의 모든 변경은 트랜잭션 안에서 동작 2) 스프링 데이터 JPA는...

# custom # 개발자 # 네이티브 # 리파지토리 # 비전공자 # 서비스 # 스프링 # 자바 # 쿼리 # Transactional # Spring # Service # Data # Impl # JPA # NativeQuery # Projections # queryDsl # readOnly # repository # 프로젝션