Skip to content

Conversation

@buzz0331
Copy link
Contributor

#️⃣ 연관된 이슈

closes #14

📝 작업 내용

  1. Post의 파생 엔티티들을 상속관계로 변경
  2. 디렉토리 구조 재설계 (이건 대면회의에서 조금더 구체화시켜야 될 것 같습니다)
  3. 복합키 제거
  4. 양방향 매핑 제거
  5. 주요 JPA 엔티티 테스트 코드 작성

Post <-> Record, Vote, Feed의 관계를 상속관계로 변경하였습니다.
테스트해보았더니 아래와 같이 post 테이블에 먼저 주입후 FK 이면서 PK로 주입되는 것을 확인 할 수 있고, 조회할때도 알아서 inner join으로 불러옵니다.

Hibernate: insert into posts (content,created_at,modified_at,status,user_id,dtype,post_id) values (?,?,?,?,?,'RECORD',default)
Hibernate: insert into records (is_overview,page,room_id,post_id) values (?,?,?,?)
Hibernate: select rje1_0.post_id,rje1_1.content,rje1_1.created_at,rje1_1.modified_at,rje1_1.status,rje1_1.user_id,rje1_0.is_overview,rje1_0.page,rje1_0.room_id from records rje1_0 join posts rje1_1 on rje1_0.post_id=rje1_1.post_id where rje1_0.post_id=?
Hibernate: select rje1_0.room_id,rje1_0.book_id,rje1_0.created_at,rje1_0.description,rje1_0.end_date,rje1_0.is_public,rje1_0.modified_at,rje1_0.password,rje1_0.recruit_count,rje1_0.room_percentage,rje1_0.start_date,rje1_0.status,rje1_0.title from rooms rje1_0 where rje1_0.room_id=?

참고글 : [JPA] 상속관계 매핑 전략(@Inheritance, @DiscriminatorColumn)

📌 PR 진행 시 이러한 점들을 참고해 주세요

* P1 : 꼭 반영해 주세요 (Request Changes) - 이슈가 발생하거나 취약점이 발견되는 케이스 등
* P2 : 반영을 적극적으로 고려해 주시면 좋을 것 같아요 (Comment)
* P3 : 이런 방법도 있을 것 같아요~ 등의 사소한 의견입니다 (Chore)

@coderabbitai
Copy link

coderabbitai bot commented Jun 20, 2025

Important

Review skipped

More than 25% of the files skipped due to max files limit. The review is being skipped to prevent a low-quality review.

36 files out of 143 files are above the max files limit of 100. Please upgrade to Pro plan to get higher limits.

You can disable this status message by setting the reviews.review_status to false in the CodeRabbit configuration file.

✨ Finishing Touches
  • 📝 Docstrings were successfully generated. (🔄 Check again to generate docstrings again)

🪧 Tips

Chat

There are 3 ways to chat with CodeRabbit:

  • Review comments: Directly reply to a review comment made by CodeRabbit. Example:
    • I pushed a fix in commit <commit_id>, please review it.
    • Explain this complex logic.
    • Open a follow-up GitHub issue for this discussion.
  • Files and specific lines of code (under the "Files changed" tab): Tag @coderabbitai in a new review comment at the desired location with your query. Examples:
    • @coderabbitai explain this code block.
    • @coderabbitai modularize this function.
  • PR comments: Tag @coderabbitai in a new PR comment to ask questions about the PR branch. For the best results, please provide a very specific query, as very limited context is provided in this mode. Examples:
    • @coderabbitai gather interesting stats about this repository and render them as a table. Additionally, render a pie chart showing the language distribution in the codebase.
    • @coderabbitai read src/utils.ts and explain its main purpose.
    • @coderabbitai read the files in the src/scheduler package and generate a class diagram using mermaid and a README in the markdown format.
    • @coderabbitai help me debug CodeRabbit configuration file.

Support

Need help? Create a ticket on our support page for assistance with any issues or questions.

Note: Be mindful of the bot's finite context window. It's strongly recommended to break down tasks such as reading entire modules into smaller chunks. For a focused discussion, use review comments to chat about specific files and their changes, instead of using the PR comments.

CodeRabbit Commands (Invoked using PR comments)

  • @coderabbitai pause to pause the reviews on a PR.
  • @coderabbitai resume to resume the paused reviews.
  • @coderabbitai review to trigger an incremental review. This is useful when automatic reviews are disabled for the repository.
  • @coderabbitai full review to do a full review from scratch and review all the files again.
  • @coderabbitai summary to regenerate the summary of the PR.
  • @coderabbitai generate docstrings to generate docstrings for this PR.
  • @coderabbitai generate sequence diagram to generate a sequence diagram of the changes in this PR.
  • @coderabbitai resolve resolve all the CodeRabbit review comments.
  • @coderabbitai configuration to show the current CodeRabbit configuration for the repository.
  • @coderabbitai help to get help.

Other keywords and placeholders

  • Add @coderabbitai ignore anywhere in the PR description to prevent this PR from being reviewed.
  • Add @coderabbitai summary to generate the high-level summary at a specific location in the PR description.
  • Add @coderabbitai anywhere in the PR title to generate the title automatically.

CodeRabbit Configuration File (.coderabbit.yaml)

  • You can programmatically configure CodeRabbit by adding a .coderabbit.yaml file to the root of your repository.
  • Please see the configuration documentation for more information.
  • If your editor has YAML language server enabled, you can add the path at the top of this file to enable auto-completion and validation: # yaml-language-server: $schema=https://coderabbit.ai/integrations/schema.v2.json

Documentation and Community

  • Visit our Documentation for detailed information on how to use CodeRabbit.
  • Join our Discord Community to get help, request features, and share feedback.
  • Follow us on X/Twitter for updates and announcements.

Copy link
Member

@hd0rable hd0rable left a comment

Choose a reason for hiding this comment

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

테스트코드까지 작성하셨네요..! 수고하셨어욧!!🤩🤩

@coderabbitai
Copy link

coderabbitai bot commented Jun 22, 2025

Warning

More than 25% of the files skipped due to max files limit. The review is being skipped to prevent a low-quality review.

36 files out of 143 files are above the max files limit of 100. Please upgrade to Pro plan to get higher limits.

@seongjunnoh seongjunnoh merged commit c581a51 into develop Jun 23, 2025
2 checks passed
@buzz0331 buzz0331 deleted the chore/#14-entity-modify branch June 24, 2025 06:39
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

[THIP2025-43] [chore] 엔티티 코드 수정

4 participants