프로젝트
📌 JPA JPA : Java 표준 ORM (Object Relational Mapping) ⚡ 패러다임 불일치 문제 관계형 데이터베이스 : 어떻게 데이터를 저장할지에 초점이 맞춰진 기술 객체지향 프로그래밍 : 언어는 메시지를 기반으로 기능과 속성을 한 곳에서 관리하는 기술 ✔ 다양한 객체 모델링을 데이터베이스로 구현할 수 없음 ✔ 웹 애플리케이션 개발은 점점 데이터베이스 모델링에만 집중!! ❗ JPA로 문제 해결 : 서로 지향하는 바가 다른 2개 영역을 중간에서 패러다임 일치를 시켜주기 위한 기술 ⚡ Spring Data JPA 인터페이스로서 자바 표준 명세서 JPA를 사용하기 위해서는 구현체 필요 Hibernate, Eclipse Link 등 ✔ 스프링에서는 JPA를 사용할 때는 구현체를 직접 다루지..
📌 Test Code ✔ TDD : 테스트가 주도하는 개발 ✔ 단위 테스트 : 기능 단위의 테스트 코드를 작성하는 것 ⚡ 단위 테스트 단위 테스트 장점 ✔ 빠른 피드백 - 코드를 수정할 때마다 톰캣을 내렸다가 다시 실행하는 일을 반복하지 않아도 됨 ✔ 자동 검증 - System.out.println()을 통해 검증 ✔ 개발자가 만든 기능 안전하게 보호 = 기존 기능이 잘 작동되는 것을 보장 테스트 코드 작성 프레임워크 xUnit JUnit - Java DBUnit - DB CppUnit - C++ NUnit - .net 우리 프로젝트에선 자바용인 JUnit5 사용 📌 Hello Controller 테스트 코드 ✔ 일반적으로 패키지 명은 웹사이트 주소의 역순 Application.java 🔶 Applica..
📌 1. 인텔리제이로 스프링 부트 시작하기 ⚡ 인텔리제이 소개 강력한 추천기능 훨씬 더 다양한 리팩토리과 디버깅 기능 이클립스의 깃(Git)에 비해 훨씬 높은 자유도 프로젝트 시작할 때 인덱싱을 하여 파일을 비롯한 자원들에 대한 빠른 검색 속도 HTML과 CSS, JS, XML에 대한 강력한 기능 지원 자바 스프링 부트 버전업에 맞춘 빠른 업데이트 ⚡ 인텔리제이에서 프로젝트 생성 스프링 이니셜라이저에서 진행할 수도 있음 GroupId와 ArtifactId 등록 ArtifactId : 프로젝트의 이름이 됨 🔶 build.gradle의 기본 코드 plugins { id 'java' id 'org.springframework.boot' version '3.1.2' id 'io.spring.dependency-..