Skip to content

Conversation

@kimhji
Copy link
Collaborator

@kimhji kimhji commented Jan 23, 2026

close #50

목적

erd 다이어그램에 맞게 엔티티 클래스를 작성하여, 이후 도메인 별 분업이 가능하도록 합니다.

작업 내용

  • Erd 다이어그램 설계

    image
  • spring boot 의존성 수정

  • env 환경 설정 기반 jdbc 연결

  • DB 마이그레이션 관리를 위한 flyway 추가

  • 복합키 및 1:N 관계에 대한 설계 완료

    • episode 클래스의 nodeId, userId 기반 pk 클래스 추가

결과

erd 설계에 맞는 엔티티 클래스 작성 완료

@kimhji kimhji requested a review from w0uldy0u January 23, 2026 07:16
@kimhji kimhji added feat 새로운 기능 추가 프로젝트 세팅 BE labels Jan 23, 2026
@gemini-code-assist
Copy link

Summary of Changes

Hello @kimhji, I'm Gemini Code Assist1! I'm currently reviewing this pull request and will post my feedback shortly. In the meantime, here's a summary to help you and other reviewers quickly get up to speed!

이 Pull Request는 ERD 다이어그램에 따라 엔티티 클래스를 작성하고, DB 마이그레이션 관리를 위한 Flyway를 추가하여 데이터베이스 구조를 설정합니다. 또한, Spring Boot 의존성을 수정하고 JDBC 연결을 설정하여 프로젝트의 기반을 마련합니다.

Highlights

  • 엔티티 클래스 작성: ERD 다이어그램에 맞춰 엔티티 클래스를 작성하여, 이후 도메인 별 분업이 가능하도록 합니다.
  • Flyway 추가: DB 마이그레이션 관리를 위해 Flyway를 추가했습니다.
  • 복합키 및 관계 설계: Episode 클래스의 nodeId, userId 기반 pk 클래스를 추가하고, 1:N 관계에 대한 설계를 완료했습니다.
  • Spring Boot 의존성 수정: Spring Boot 의존성을 수정하고, env 환경 설정 기반으로 JDBC 연결을 설정했습니다.
Using Gemini Code Assist

The full guide for Gemini Code Assist can be found on our documentation page, here are some quick tips.

Invoking Gemini

You can request assistance from Gemini at any point by creating a comment using either /gemini <command> or @gemini-code-assist <command>. Below is a summary of the supported commands on the current page.

Feature Command Description
Code Review /gemini review Performs a code review for the current pull request in its current state.
Pull Request Summary /gemini summary Provides a summary of the current pull request in its current state.
Comment @gemini-code-assist Responds in comments when explicitly tagged, both in pull request comments and review comments.
Help /gemini help Displays a list of available commands.

Customization

To customize Gemini Code Assist for GitHub experience, repository maintainers can create a configuration file and/or provide a custom code review style guide (such as PEP-8 for Python) by creating and adding files to a .gemini/ folder in the base of the repository. Detailed instructions can be found here.

Limitations & Feedback

Gemini Code Assist may make mistakes. Please leave feedback on any instances where its feedback is incorrect or counter productive. You can react with 👍 and 👎 on @gemini-code-assist comments. If you're interested in giving your feedback about your experience with Gemini Code Assist for Github and other Google products, sign up here.

You can also get AI-powered code generation, chat, as well as code reviews directly in the IDE at no cost with the Gemini Code Assist IDE Extension.

Footnotes

  1. Review the Privacy Notices, Generative AI Prohibited Use Policy, Terms of Service, and learn how to configure Gemini Code Assist in GitHub here. Gemini can make mistakes, so double check it and use code with caution.

Copy link

@gemini-code-assist gemini-code-assist bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Code Review

ERD에 맞춰 엔티티를 작성하는 PR 잘 보았습니다. 전반적으로 JPA 엔티티와 관계 설정이 잘 되어있습니다. Flyway를 도입하여 데이터베이스 스키마를 관리하는 점도 좋습니다. 다만, 몇 가지 개선할 점들이 보입니다. 특히 gradle.properties에 개인 로컬 경로가 포함된 점, application.propertiesddl-auto 설정, 그리고 CompetencyType 엔티티의 enum과 DB 스키마 간의 불일치 등은 수정이 필요해 보입니다. 또한, 여러 엔티티 클래스에서 @Setter를 사용하는 것이나 불필요한 import문, 중복된 repository 메소드 등 유지보수성을 높이기 위한 몇 가지 제안 사항들을 리뷰에 남겼습니다. 자세한 내용은 각 파일의 리뷰 코멘트를 확인해주세요.

-- -----------------------------------------------------
-- Table `episode_db_v0`.`occupation`
-- -----------------------------------------------------
CREATE TABLE `episode_db_v0`.`occupation` (

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

medium

SQL 스크립트 전체에 걸쳐 데이터베이스 이름(episode_db_v0)이 하드코딩되어 있습니다. 이렇게 하면 개발, 테스트, 프로덕션 환경마다 다른 데이터베이스 이름을 사용할 경우 유연성이 떨어집니다. 데이터베이스 연결 URL에서 데이터베이스 이름을 지정하고, 마이그레이션 스크립트에서는 테이블 이름만 사용하도록 episode_db_v0. 부분을 제거하는 것이 일반적입니다.

CREATE TABLE `occupation` (

Comment on lines 51 to 52
ON DELETE NO ACTION
ON UPDATE NO ACTION)

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

medium

users 테이블의 job_id 외래 키에 ON DELETE NO ACTION이 설정되어 있습니다. 이는 참조하는 job이 삭제될 때 작업이 실패하도록 합니다. 다른 테이블에서는 ON DELETE CASCADE를 사용하는 등 정책이 일관되지 않습니다. 예를 들어 question 테이블의 job_idON DELETE CASCADE로 설정되어 있습니다. 프로젝트의 요구사항에 맞게 외래 키 제약 조건의 ON DELETE 정책을 일관성 있게 검토하고 수정하는 것이 좋습니다. question2competency_type (lines 86-87) 와 experience2user (lines 129-130) 제약조건도 같은 맥락에서 검토가 필요합니다.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

BE feat 새로운 기능 추가 프로젝트 세팅

Projects

None yet

Development

Successfully merging this pull request may close these issues.

[BE] 프로젝트 세팅

3 participants