spring boot 3

Referencing column 'manager _id' and referenced column 'auth_id' in foreign key constraint 'FKk9ovx8ldyjxtp4blkciobskyo' are incompatible.

현재 상황auth_ID를 UUID로 변경한 후, 기존 DB의 auth_id가 Long으로 지정되어 있어서 에러가 발생해결 방법개발 단계이고, DB에 데이터가 없어서 jpa.hibernate.ddl-auto를 create-drop으로 설정한 후 실행했다.그 후 update로 변경후 API를 테스트했더니 문제없이 작동되었다. jpa: properties: hibernate: show_sql: true format_sql: true hibernate: ddl-auto: create-drop

카테고리 없음 2024.09.20

org.hibernate.annotations.GenericGenerator' is deprecated since version 6.5

@Id@GeneratedValue(generator = "uuid2")@GenericGenerator(name="uuid2", strategy = "uuid2")@Column(name = "auth_id", columnDefinition = "BINARY(16)")private UUID id; 기존 Auto Increment pk를 보안성 이슈로 UUID로 바꾸는 것이 좋겠다는 피드백을 받았다.블로그를 참조한 후 UUID를 적용하였지만, @GenericGenerator가 deprecated되었다는 경고가 발생했다. 다음과 같이 변경해주었다.@Id@GeneratedValue(strategy = GenerationType.UUID)@Column(name = "auth_id", columnDefinition ..

카테고리 없음 2024.09.20