본문 바로가기

sns3

API / JPA 로직 별 실행되는 쿼리 확인 API 정보는 이전 정리한 페이지 참조 1. 회원 가입 로직 @Transactional // exception나면 rollback 위한 어노테이션 public User join(String userName, String password){ // 회원가입하려하는 userName으로 회원가입된 user가 있는지 userEntityRepository.findByUserName(userName).ifPresent(it ->{ throw new SnsApplicationException(ErrorCode.DUPLICATED_USER_NAME, String.format("%s is duplicated", userName)); }); // 회원가입 진행 = user를 등록 UserEntity userEntity = .. 2024. 1. 4.
서버 부팅 시 Table 자동 생성되는 Hibernate 쿼리 기록 Hibernate: alter table alarm drop foreign key FKjdot8d6e1wmd227isu080k760 Hibernate: alter table alarm drop foreign key FK6yk93nqmu865xvtraxe3p3q7r Hibernate: alter table comment drop foreign key FKs1slvnkuemjsq2kj4h3vhx7i1 Hibernate: alter table comment drop foreign key FKn6xssinlrtfnm61lwi0ywn71q Hibernate: alter table liked drop foreign key FKt22ayicw3p3ho63o5e9wl8dgv Hibernate: alter table l.. 2024. 1. 4.
프로젝트 api 정리 강의 있는 패캠 아이디 : yeongbin6####@gmail.com Redis Version docker ps docker exec -it myredis bash redis-cli info redis_version:7.0.4 MySQL Version docker exec -it mysql-container bash mysql --version mysql version : 8.1.0 1. 회원가입 POST : http://127.0.0.1:9090/api/v1/users/join Header Content-Type : application/json BODY { "name":"ccc", "password":"bbb" } RESPONSE { "resultCode": "SUCCESS", "result": { .. 2023. 12. 30.