기록을 합시다.

설정 spring boot 버전 : 3.0.6 dependency 설정 dependencies { implementation 'org.springframework.boot:spring-boot-starter-data-jpa' annotationProcessor 'org.projectlombok:lombok' compileOnly 'org.projectlombok:lombok' developmentOnly 'org.springframework.boot:spring-boot-devtools' //spring security implementation 'org.springframework.boot:spring-boot-starter-security' //jwt implementation 'io.jsonwebt..
JPA(Java Persistence API) JPA - Introduction JPA Introduction - Any enterprise application performs database operations by storing and retrieving vast amounts of data. Despite all the available technologies for storage management, application developers normally struggle to perform database operation www.tutorialspoint.com Java Persistence API는 방대한 양의 데이터를 데이터베이스에 지속적으로 저장하기 위한 클래스와 메서드의 모음이다. J..
Dependency 등록 [project]에 pom.xml 파일에 dependency 3개 등록해준다. Maven Repository: org.springframework.security » spring-security-core (mvnrepository.com) Maven Repository: org.springframework.security » spring-security-web (mvnrepository.com) Maven Repository: org.springframework.security » spring-security-config (mvnrepository.com) //pom.xml org.springframework.security spring-security-core 5.0.8.REL..
오류 내용 org.hibernate.tool.schema.spi.CommandAcceptanceException: Error executing DDL "alter table if exists freeboard add constraint FK7wpguxmg9tgfbx9yi8p9to7ju foreign key (user_id) references user" via JDBC Statement at org.hibernate.tool.schema.internal.exec.GenerationTargetToDatabase.accept(GenerationTargetToDatabase.java:67) ~[hibernate-core-6.1.7.Final.jar:6.1.7.Final] at org.hibernate.tool..

build.gradle 설정 dependencies { developmentOnly 'org.springframework.boot:spring-boot-devtools' } `spring-boot-devtools` 모듈은 애플리케이션의 코드나 리소스가 변경될 때 자동으로 리스타트해주고, 라이브 리로딩, 자동 구성 등의 기능을 제공해준다. application.properties 설정 # Spring dev-tools livereload.enabled=true freemarker.cache=false `livereload.enabled=true`는 개발 중인 애플리케이션을 수정할 때 자동으로 애플리케이션을 리로드해주는 기능을 활성화해준다. `freemarker.cache=false`는 템플릿 캐시를 사용하..

오류메시지 Warning: useLayoutEffect does nothing on the server, because its effect cannot be encoded into the server renderer's output format. This will lead to a mismatch between the initial, non-hydrated UI and the intended UI. To avoid this, useLayoutEffect should only be used in components that render exclusively on the client. See https://reactjs.org/link/uselayouteffect-ssr for common fixes. at..

사전 지식 VO [Spring] DAO, DTO, VO (tistory.com) @Controller @Controller 애노테이션은 Spring MVC에서 Controller 클래스에 대해 정의한다. 이 애노테이션이 붙은 클래스는 HTTP 요청을 처리하고, 처리한 결과를 응답해준다. @GetMapping @GetMapping은 HTTP GET 요청을 처리하는 메서드를 정의할 때 사용한다. 메서드에 붙이게 되면, 해당 URL 경로의 GET 요청을 처리하게 된다. @PostMapping @PostMapping은 HTTP POST 요청을 처리하는 메서드를 정의할 때 사용한다. 메서드에 붙이면, 해당 URL 경로의 POST 요청을 처리한다. HTML 파일 function register(){ if($("#u..
DAO, DTO, VO Spring에서 데이터를 다룰 때 사용되는 클래스들에는 DTO, VO, DAO가 있다. 이 클래스들을 사용 할 때, 각 클레스가 어떤 역할을 수행하는지 명확하게 구분하고 사용하면 코드의 가독성과 유지보수성을 높일 수 있다. DAO(Data Transfer Object) 데이터를 영구 저장소(DB, 파일)에 접근하는 객체로, 데이터베이스의 CRUD 작업을 처리해준다. DAO는 비즈니스 로직과 영속적 로직을 분리해주어 유지보수성과 확장성을 높이는 데 사용한다. DTO(Data Access Objec) 계층 간 데이터 교환을 위한 객체로, 계층간의 데이터 교환을 위해 사용한다. DB에서 가져온 데이터를 Controller 혹은 Service에서 처리하기 적합한 형태로 변환해준다. DTO..