스프링부트 - 데이터베이스 연동


## 디펜던시 설정

- Web
- Lombok
- JPA
- MyBatis
- H2, MariaDB, PostgreSQL 드라이버

## Entity와 JPARepository

- @Entity : [Post.java](http://Post.java) 를 엔티티로 변환
- @Service
- Repository 인터페이스

## 프로파일 분리

- application.yml
- application-local.yml
- application-dev.yml
- application-prod.yml

## MyBatis

- MyBatis 설정
- 프로파일별 데이터베이스 분리

## 페이징과 검색

- JPA
    - Query Creation
    - Paging
- MyBatis
    - paging

## 참고문헌

[mybatis-spring-boot-autoconfigure – Introduction](https://mybatis.org/spring-boot-starter/mybatis-spring-boot-autoconfigure/)

[Spring Data JPA - Reference Documentation](https://docs.spring.io/spring-data/jpa/docs/current/reference/html/#jpa.query-methods.query-creation)


댓글

이 블로그의 인기 게시물

Session 대신 JWT를 사용하는 이유

VSCode에서의 VIM 단축키와 키보드 구매 가이드

우분투에서 테스트링크(testlink)와 맨티스(mantis)로 테스팅 서버 구성하기