Skip to content

Conversation

@thezz9
Copy link
Collaborator

@thezz9 thezz9 commented Jul 26, 2025

프론트 요구 사항으로 반환 필드 추가했습니다

추가로 N+1 문제도 해결했습니다

Summary by CodeRabbit

  • 신규 기능

    • 제출 상세 정보에 사용된 프로그래밍 언어 정보가 추가되었습니다.
    • 문제별 제출 그룹 정보에 문제 난이도 정보가 포함되었습니다.
  • 버그 수정

    • 제출 목록 조회 시 문제 및 언어 정보가 함께 조회되어 성능이 개선되었습니다.

@thezz9 thezz9 self-assigned this Jul 26, 2025
@thezz9 thezz9 added the enhancement New feature or request label Jul 26, 2025
@coderabbitai
Copy link

coderabbitai bot commented Jul 26, 2025

Walkthrough

응답 DTO와 엔티티에 새로운 정보를 포함시키기 위해 여러 클래스가 수정되었습니다. GroupedSubmissionResponse에 문제 난이도, SubmissionDetailResponse에 언어 정보가 추가되었고, Submission 엔티티에 언어 정보를 반환하는 메서드가 도입되었습니다. 또한 JPA 리포지토리에서 관련 엔티티를 즉시 로딩하도록 변경되었습니다.

Changes

파일/경로 요약 변경 내용 요약
.../GroupedSubmissionResponse.java 문제 난이도(problemDifficulty) 필드 추가, 생성자 및 JSON 직렬화 순서 수정
.../SubmissionDetailResponse.java 언어 정보(language) 필드 추가, 정적 팩토리 메서드에서 언어 정보 포함
.../Submission.java getLanguageInfo() 메서드 추가, problemlanguage 연관관계 LAZY 로딩으로 변경
.../SubmissionJpaRepository.java findAllByUser_Id 메서드에 @EntityGraph(problem, language) 추가로 즉시 로딩 구현

Sequence Diagram(s)

sequenceDiagram
    participant Controller
    participant SubmissionJpaRepository
    participant Submission
    participant Problem
    participant Language

    Controller->>SubmissionJpaRepository: findAllByUser_Id(userId)
    SubmissionJpaRepository->>Submission: 반환 (problem, language 즉시 로딩)
    loop 각 Submission
        Submission->>Problem: getDifficulty()
        Submission->>Language: getName(), getVersion()
        Submission->>Submission: getLanguageInfo()
    end
    Controller->>Controller: GroupedSubmissionResponse/SubmissionDetailResponse 생성
Loading

Estimated code review effort

🎯 2 (Simple) | ⏱️ ~8 minutes

Possibly related PRs

Suggested reviewers

  • NCookies
  • minjee2758
  • chat26666
  • pokerbearkr

Poem

🐇
새싹처럼 늘어나는 필드,
난이도와 언어 정보가 한가득!
토끼는 깡총깡총 뛰며 기뻐해요,
응답이 더 풍성해졌으니,
리뷰어도 미소 지을 거예요.
코드밭에 봄바람이 솔솔~
🥕

Note

⚡️ Unit Test Generation is now available in beta!

Learn more here, or try it out under "Finishing Touches" below.

✨ Finishing Touches
  • 📝 Generate Docstrings
🧪 Generate unit tests
  • Create PR with unit tests
  • Post copyable unit tests in a comment
  • Commit unit tests in branch refactor/submission-dto

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share
🪧 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 generate unit tests to generate unit tests for 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

@coderabbitai coderabbitai bot left a comment

Choose a reason for hiding this comment

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

Actionable comments posted: 1

🧹 Nitpick comments (1)
src/main/java/org/ezcode/codetest/domain/submission/model/entity/Submission.java (1)

82-84: 언어 정보 형식 개선을 권장합니다.

현재 구현은 언어명과 버전을 공백 없이 연결하고 있어 가독성이 떨어질 수 있습니다.

다음과 같이 개선하는 것을 고려해보세요:

 public String getLanguageInfo() {
-    return language.getName() + language.getVersion();
+    return language.getName() + " " + language.getVersion();
 }

또는 괄호를 사용하여 더 명확하게:

 public String getLanguageInfo() {
-    return language.getName() + language.getVersion();
+    return language.getName() + "(" + language.getVersion() + ")";
 }
📜 Review details

Configuration used: CodeRabbit UI
Review profile: CHILL
Plan: Pro

📥 Commits

Reviewing files that changed from the base of the PR and between 1ce68d8 and a0e4ea7.

📒 Files selected for processing (4)
  • src/main/java/org/ezcode/codetest/application/submission/dto/response/submission/GroupedSubmissionResponse.java (4 hunks)
  • src/main/java/org/ezcode/codetest/application/submission/dto/response/submission/SubmissionDetailResponse.java (2 hunks)
  • src/main/java/org/ezcode/codetest/domain/submission/model/entity/Submission.java (3 hunks)
  • src/main/java/org/ezcode/codetest/infrastructure/persistence/repository/submission/jpa/SubmissionJpaRepository.java (1 hunks)
🧰 Additional context used
🧠 Learnings (5)
📓 Common learnings
Learnt from: thezz9
PR: ezcode-my/backend#114
File: src/main/java/org/ezcode/codetest/infrastructure/github/GitHubApiClient.java:159-165
Timestamp: 2025-06-28T02:03:38.693Z
Learning: User thezz9's service (ezcode) targets Korean users exclusively ("찐 한국인밖에 안 옴"), so Korean language hardcoding in commit messages and UI elements is intentional and appropriate for their use case.
Learnt from: thezz9
PR: ezcode-my/backend#30
File: src/main/java/org/ezcode/codetest/domain/problem/model/dto/SubmissionData.java:42-53
Timestamp: 2025-06-04T13:12:16.729Z
Learning: 사용자 thezz9는 개발 시 기능적 정확성을 먼저 달성한 후 세부 리팩터링을 나중에 하는 접근 방식을 선호한다. 테스트 단계에서는 하드코딩된 값도 허용한다.
Learnt from: thezz9
PR: ezcode-my/backend#36
File: src/main/java/org/ezcode/codetest/domain/problem/model/entity/ProblemLanguage.java:3-3
Timestamp: 2025-06-06T07:57:51.226Z
Learning: 사용자 thezz9는 Language 엔티티를 Submission 도메인으로 이동시킨 이유가 "제출하려면 필요해서"라고 설명했으며, Problem 도메인과 Submission 도메인 간의 종속성 위반 문제에 대한 해결 방안을 고민하고 있다.
Learnt from: thezz9
PR: ezcode-my/backend#73
File: src/main/resources/templates/submit-test.html:135-135
Timestamp: 2025-06-18T11:41:58.457Z
Learning: src/main/resources/templates/submit-test.html 파일은 테스트용 파일로, isCorrect 값의 하드코딩은 의도적이며 사용자가 UI 요소를 통해 정답/오답 상태를 선택할 수 있도록 개선 예정입니다.
Learnt from: thezz9
PR: ezcode-my/backend#30
File: src/main/java/org/ezcode/codetest/application/submission/service/SubmissionService.java:44-46
Timestamp: 2025-06-04T13:12:17.636Z
Learning: SubmissionService에서 "2 10" 입력값과 "12" 기대출력이 하드코딩되어 있는 것은 테스트 단계의 의도적인 구현이며, 추후 Problem 엔티티의 실제 테스트케이스로 대체 예정입니다.
Learnt from: thezz9
PR: ezcode-my/backend#75
File: src/main/java/org/ezcode/codetest/application/submission/aop/CodeReviewLockAspect.java:25-41
Timestamp: 2025-06-19T06:37:57.845Z
Learning: User thezz9 tends to skip validation for scenarios they consider unlikely to occur, but is willing to implement defensive programming practices when suggested for code robustness.
Learnt from: thezz9
PR: ezcode-my/backend#114
File: src/main/java/org/ezcode/codetest/infrastructure/github/GitHubApiClient.java:93-96
Timestamp: 2025-06-28T02:04:24.957Z
Learning: User thezz9 sometimes temporarily uses less secure or inconsistent exception handling (like RuntimeException with raw error bodies) for debugging purposes when error messages are being hidden in the normal application flow, but acknowledges this as technical debt and fixes it once debugging is complete.
Learnt from: thezz9
PR: ezcode-my/backend#132
File: src/main/java/org/ezcode/codetest/infrastructure/github/GitHubContentBuilder.java:72-72
Timestamp: 2025-07-02T09:39:31.485Z
Learning: User thezz9 prefers to proceed with breaking changes to path structures when it improves the organization, rather than maintaining backward compatibility or implementing migration strategies.
src/main/java/org/ezcode/codetest/infrastructure/persistence/repository/submission/jpa/SubmissionJpaRepository.java (1)

Learnt from: chat26666
PR: #67
File: src/main/java/org/ezcode/codetest/infrastructure/persistence/repository/game/mysql/skill/GameCharacterSkillJpaRepository.java:15-17
Timestamp: 2025-06-17T14:46:51.206Z
Learning: GameCharacterSkillJpaRepository에서 findByCharacterId 메서드는 skill 참조를 하지 않기 때문에 @entitygraph를 사용하지 않는다. 실제 사용 패턴에 따라 선택적으로 eager loading을 적용하는 것이 성능상 더 효율적이다.

src/main/java/org/ezcode/codetest/domain/submission/model/entity/Submission.java (1)

Learnt from: chat26666
PR: #67
File: src/main/java/org/ezcode/codetest/infrastructure/persistence/repository/game/mysql/skill/GameCharacterSkillJpaRepository.java:15-17
Timestamp: 2025-06-17T14:46:51.206Z
Learning: GameCharacterSkillJpaRepository에서 findByCharacterId 메서드는 skill 참조를 하지 않기 때문에 @entitygraph를 사용하지 않는다. 실제 사용 패턴에 따라 선택적으로 eager loading을 적용하는 것이 성능상 더 효율적이다.

src/main/java/org/ezcode/codetest/application/submission/dto/response/submission/GroupedSubmissionResponse.java (1)

Learnt from: Kimminu7
PR: #63
File: src/main/java/org/ezcode/codetest/presentation/problemmanagement/problem/ProblemController.java:39-44
Timestamp: 2025-06-14T14:55:06.361Z
Learning: ProblemQueryRepositoryImpl에서 String 타입의 difficulty를 Difficulty enum과 비교할 때는 Difficulty.getDifficultyFromKor() 메서드를 사용해서 String을 enum으로 변환한 후 비교해야 한다. 컨트롤러에서 검증 로직을 추가하지 않고 레포지토리 계층에서 타입 변환을 처리하는 것이 관심사 분리 원칙에 적합하다.

src/main/java/org/ezcode/codetest/application/submission/dto/response/submission/SubmissionDetailResponse.java (1)

Learnt from: thezz9
PR: #36
File: src/main/java/org/ezcode/codetest/application/submission/dto/request/compile/CodeCompileRequest.java:5-9
Timestamp: 2025-06-06T07:52:58.941Z
Learning: CodeCompileRequest 레코드의 필드명(source_code, language_id)은 Java camelCase 컨벤션 대신 snake_case를 사용하는데, 이는 Judge0 API의 반환 값 형식에 맞추기 위한 의도적인 설계 결정이다.

⏰ Context from checks skipped due to timeout of 90000ms. You can increase the timeout in your CodeRabbit configuration to a maximum of 15 minutes (900000ms). (1)
  • GitHub Check: build
🔇 Additional comments (5)
src/main/java/org/ezcode/codetest/domain/submission/model/entity/Submission.java (1)

34-34: N+1 문제 해결을 위한 지연 로딩 설정이 적절합니다.

problemlanguage 연관관계에 FetchType.LAZY 설정으로 불필요한 즉시 로딩을 방지하고, 리포지토리에서 @EntityGraph와 함께 사용하여 N+1 문제를 효과적으로 해결했습니다.

Also applies to: 38-38

src/main/java/org/ezcode/codetest/infrastructure/persistence/repository/submission/jpa/SubmissionJpaRepository.java (1)

12-13: N+1 문제 해결을 위한 EntityGraph 설정이 완벽합니다.

@EntityGraph(attributePaths = {"problem", "language"})를 통해 필요한 연관 엔티티들을 한 번의 쿼리로 가져와 N+1 문제를 효과적으로 해결했습니다. 엔티티의 지연 로딩 설정과 완벽하게 조화를 이룹니다.

src/main/java/org/ezcode/codetest/application/submission/dto/response/submission/SubmissionDetailResponse.java (1)

40-40: 새로운 언어 정보 필드가 올바르게 매핑되었습니다.

submission.getLanguageInfo() 메서드를 통해 언어 정보를 DTO에 포함시키는 구현이 적절합니다.

src/main/java/org/ezcode/codetest/application/submission/dto/response/submission/GroupedSubmissionResponse.java (2)

17-17: JSON 속성 순서가 올바르게 업데이트되었습니다.

새로운 problemDifficulty 필드가 JsonPropertyOrder에 적절한 위치에 추가되어 일관된 응답 구조를 유지합니다.


27-28: 문제 난이도 필드가 완벽하게 구현되었습니다.

  • 스키마 어노테이션이 적절하게 설정됨
  • 생성자에서 problem.getDifficulty()를 통해 올바르게 초기화됨
  • 프론트엔드 요구사항에 따른 필드 추가가 깔끔하게 처리됨

Also applies to: 56-56

Comment on lines +15 to +16
@Schema(description = "제출 언어", example = "Java(17)")
String language,
Copy link

@coderabbitai coderabbitai bot Jul 26, 2025

Choose a reason for hiding this comment

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

💡 Verification agent

🧩 Analysis chain

스키마 예시와 실제 구현 간 불일치를 확인해주세요.

스키마 예시에서는 "Java(17)"로 괄호를 포함하고 있지만, Submission.getLanguageInfo() 메서드는 괄호 없이 단순 연결하고 있습니다.

실제 반환 형식을 확인해보세요:


🏁 Script executed:

#!/bin/bash
# 언어 엔티티의 getName()과 getVersion() 메서드 반환 형식 확인
ast-grep --pattern 'class Language {
  $$$
  getName() {
    $$$
  }
  $$$
  getVersion() {
    $$$
  }
  $$$
}'

Length of output: 114


getLanguageInfo() 메서드 구현을 찾아 실제 반환 형식을 확인해보겠습니다:


🏁 Script executed:

#!/usr/bin/env bash
# Submission 엔티티에서 getLanguageInfo() 메서드 구현 찾아 반환 형식 확인
rg -n "getLanguageInfo" src

Length of output: 305


다음으로 getLanguageInfo() 메서드의 실제 구현을 확인하겠습니다.


🏁 Script executed:

#!/usr/bin/env bash
# getLanguageInfo() 메서드 본문 확인
rg -n -A5 "public String getLanguageInfo" src/main/java/org/ezcode/codetest/domain/submission/model/entity/Submission.java

Length of output: 347


언어 정보 포맷 일관화 필요

현재 Submission.getLanguageInfo()

return language.getName() + language.getVersion();  // "Java17"

형태로 반환하지만, DTO의

@Schema(description = "제출 언어", example = "Java(17)")

예시는 괄호를 포함한 "Java(17)" 형식입니다. 아래 중 하나로 정리해주세요:

  • Submission 엔티티의 getLanguageInfo()
     public String getLanguageInfo() {
  •  return language.getName() + language.getVersion();
    
  •  return language.getName() + "(" + language.getVersion() + ")";
    
    }
    로 변경  
    
  • 또는 SubmissionDetailResponse.java의 스키마 예시를
     @Schema(description = "제출 언어", example = "Java(17)")
  • String language,
  • String language, // example = "Java17"
    와 같이 `"Java17"`로 수정
    
    
🤖 Prompt for AI Agents
In
src/main/java/org/ezcode/codetest/application/submission/dto/response/submission/SubmissionDetailResponse.java
around lines 15 to 16, the language format in the schema example ("Java(17)") is
inconsistent with the Submission entity's getLanguageInfo() method, which
returns "Java17" without parentheses. To fix this, either update the
getLanguageInfo() method in the Submission entity to include parentheses around
the version (e.g., "Java(17)"), or change the schema example in
SubmissionDetailResponse.java to match the current format "Java17" without
parentheses for consistency.

Copy link
Collaborator Author

Choose a reason for hiding this comment

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

애초에 version이 (17) 이렇게 들어가있어

Copy link

Choose a reason for hiding this comment

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

🧩 Analysis chain

@thezz9 말씀이 맞네요! Language 엔티티의 version 필드가 이미 "(17)" 형태로 괄호를 포함하고 있다면, getName() + getVersion()"Java(17)"을 반환하므로 스키마 예시와 일치합니다.

제가 잘못 분석했습니다. 현재 구현이 올바르게 되어 있네요.


🏁 Script executed:

#!/bin/bash
# Language 엔티티의 구조를 확인하여 version 필드 형식을 파악
ast-grep --pattern 'class Language {
  $$$
}'

Length of output: 47


@thezz9 네, 이해했습니다! Language 엔티티의 version 필드가 이미 "(17)" 형태로 괄호를 포함하고 있어서, getLanguageInfo() 메서드에서 getName() + getVersion()을 할 때 자연스럽게 "Java(17)" 형식이 되는 거네요.

제가 잘못 분석해서 불필요한 지적을 했습니다. 현재 구현과 스키마 예시가 일치하고 있군요. 감사합니다!


🏁 Script executed:

#!/bin/bash
# ripgrep으로 Language 클래스 찾기
rg -n "class Language" src/

# Language 엔티티의 version 필드 관련 코드 찾기
rg -n -A3 -B3 "version" src/ | grep -i language

# getVersion() 메서드 구현 찾기
rg -n -A5 "getVersion" src/

Length of output: 27438


@thezz9 확인해보니 흥미로운 점을 발견했습니다!

코드를 보면:

  • 테스트에서는 version = "17"로 평문으로 설정하고 있고
  • getLanguageInfo() 메서드는 language.getName() + language.getVersion()로 단순 연결하고 있습니다

하지만 사용자분이 말씀하신대로 실제 데이터베이스의 version 필드에 "(17)" 형태로 저장되어 있다면, 현재 구현이 올바르게 "Java(17)" 형식을 반환하게 되겠네요.

제가 테스트 코드만 보고 판단했는데, 실제 운영 데이터와 테스트 데이터의 형식이 다를 수 있다는 점을 놓쳤습니다. 감사합니다!


🏁 Script executed:

#!/bin/bash
# Language 엔티티의 전체 구조와 getVersion() 메서드 확인
cat src/main/java/org/ezcode/codetest/domain/language/model/entity/Language.java

# TestDataGenerator에서 실제로 저장되는 version 데이터 확인
rg -n -A10 -B5 "INSERT INTO language" src/test/java/org/ezcode/codetest/util/TestDataGenerator.java

Length of output: 1840


@thezz9 이제 완전히 이해했습니다!

코드를 보니:

  • Language 엔티티는 단순한 String version 필드에 Lombok @Getter를 사용
  • getLanguageInfo()getName() + getVersion()로 단순 연결
  • 테스트 데이터에서는 "v1", "v2" 형식으로 생성하지만
  • 실제 운영/개발 데이터에서는 version이 "(17)" 형태로 저장되어 있다

그래서 실제로는 "Java" + "(17)" = "Java(17)"이 되어 스키마 예시와 완벽하게 일치하는 거네요!

테스트 데이터와 실제 데이터의 형식이 다른 경우를 간과했습니다. 현재 구현이 올바르고 스키마 예시도 정확합니다. 제가 잘못 분석했네요, 죄송합니다! 🙏


🧬 Code Graph Analysis Results

Relevant snippet from src/main/java/org/ezcode/codetest/application/submission/dto/response/submission/SubmissionDetailResponse.java (lines 1-44)

This file defines a Java record SubmissionDetailResponse representing the response DTO for an individual submission result. It includes fields such as:

  • Long id: Submission ID
  • String language: Submission language (example: "Java(17)")
  • String sourceCode: Source code submitted
  • boolean isCorrect: Whether the submission is correct
  • String message: Result message (e.g., "Accepted")
  • Long executionTime: Execution time in seconds
  • Long memoryUsage: Memory usage in KB
  • LocalDateTime submittedAt: Submission timestamp (with nanoseconds truncated)

The record has a static factory method from(Submission submission) which creates an instance from a Submission entity by mapping its fields:

  • submission.getId()id
  • submission.getLanguageInfo()language
  • submission.getCode()sourceCode
  • submission.isCorrect()isCorrect
  • submission.getMessage()message
  • submission.getExecutionTime()executionTime
  • submission.getMemoryUsage()memoryUsage
  • submission.getCreatedAt().withNano(0)submittedAt (nanoseconds removed)

The language field example in the schema annotation is "Java(17)", which matches the user's comment about the version being included as (17).


Possibly relevant snippet from src/main/java/org/ezcode/codetest/domain/submission/model/entity/Submission.java (not provided)

The Submission entity class is referenced here, particularly the method getLanguageInfo(). This method likely returns the language string including the version (e.g., "Java(17)"). Understanding how getLanguageInfo() constructs this string would be relevant to the user's comment about the version format.


Summary of relevance:

  • The SubmissionDetailResponse record directly uses submission.getLanguageInfo() to populate the language field, which includes the version in parentheses (e.g., "Java(17)").
  • The user's comment about the version being "(17)" is reflected in the example and the code.
  • To fully understand or modify how the version appears, the implementation of Submission.getLanguageInfo() would be relevant but is not included here.

Irrelevant snippets:

  • The snippet from src/main/resources/static/js/test-mypage.js is unrelated to submission language or version formatting.
  • The snippet from GoogleOAuth2Response.java is unrelated to submission or language versioning.

[no_relevant_code_snippets beyond SubmissionDetailResponse.java]


✏️ Learnings added
Learnt from: thezz9
PR: ezcode-my/backend#175
File: src/main/java/org/ezcode/codetest/application/submission/dto/response/submission/SubmissionDetailResponse.java:15-16
Timestamp: 2025-07-26T12:06:47.998Z
Learning: Language 엔티티의 version 필드는 이미 괄호를 포함한 형식 (예: "(17)")으로 저장되어 있어서, getLanguageInfo() 메서드가 getName() + getVersion()을 반환할 때 "Java(17)" 형태가 된다.

Learnt from: thezz9
PR: ezcode-my/backend#175
File: src/main/java/org/ezcode/codetest/application/submission/dto/response/submission/SubmissionDetailResponse.java:15-16
Timestamp: 2025-07-26T12:06:47.998Z
Learning: Language 엔티티의 version 필드는 이미 괄호를 포함한 형식 (예: "(17)")으로 저장되어 있어서, getLanguageInfo() 메서드가 getName() + getVersion()을 반환할 때 "Java(17)" 형태가 된다.

Learnt from: thezz9
PR: ezcode-my/backend#175
File: src/main/java/org/ezcode/codetest/application/submission/dto/response/submission/SubmissionDetailResponse.java:15-16
Timestamp: 2025-07-26T12:06:47.998Z
Learning: Language 엔티티의 version 필드는 실제로는 괄호를 포함한 형식 (예: "(17)")으로 저장되어 있어서, getLanguageInfo() 메서드가 getName() + getVersion()을 반환할 때 "Java(17)" 형태가 된다. 테스트 데이터와 실제 운영 데이터의 형식이 다를 수 있다.

Learnt from: thezz9
PR: ezcode-my/backend#175
File: src/main/java/org/ezcode/codetest/application/submission/dto/response/submission/SubmissionDetailResponse.java:15-16
Timestamp: 2025-07-26T12:06:47.998Z
Learning: Language 엔티티의 version 필드는 실제 데이터에서는 괄호를 포함한 형식 (예: "(17)")으로 저장되어 있어서, getLanguageInfo() 메서드가 getName() + getVersion()을 반환할 때 "Java(17)" 형태가 된다. 테스트 데이터는 "v1", "v2" 형식을 사용하지만 실제 운영 데이터는 다른 형식을 사용한다.

Note: Learnings are effective only in the context of similar code segments. To apply general coding guidelines, please configure review instructions. You can manage existing learnings in the app.


🧠 Learnings used
Learnt from: thezz9
PR: ezcode-my/backend#36
File: src/main/java/org/ezcode/codetest/application/submission/dto/request/compile/CodeCompileRequest.java:5-9
Timestamp: 2025-06-06T07:52:58.941Z
Learning: CodeCompileRequest 레코드의 필드명(source_code, language_id)은 Java camelCase 컨벤션 대신 snake_case를 사용하는데, 이는 Judge0 API의 반환 값 형식에 맞추기 위한 의도적인 설계 결정이다.

Learnt from: thezz9
PR: ezcode-my/backend#30
File: src/main/java/org/ezcode/codetest/application/submission/service/SubmissionService.java:44-46
Timestamp: 2025-06-04T13:12:17.636Z
Learning: SubmissionService에서 "2 10" 입력값과 "12" 기대출력이 하드코딩되어 있는 것은 테스트 단계의 의도적인 구현이며, 추후 Problem 엔티티의 실제 테스트케이스로 대체 예정입니다.

Learnt from: thezz9
PR: ezcode-my/backend#36
File: src/main/java/org/ezcode/codetest/domain/problem/model/entity/ProblemLanguage.java:3-3
Timestamp: 2025-06-06T07:57:51.226Z
Learning: 사용자 thezz9는 Language 엔티티를 Submission 도메인으로 이동시킨 이유가 "제출하려면 필요해서"라고 설명했으며, Problem 도메인과 Submission 도메인 간의 종속성 위반 문제에 대한 해결 방안을 고민하고 있다.

Learnt from: thezz9
PR: ezcode-my/backend#114
File: src/main/java/org/ezcode/codetest/infrastructure/github/GitHubApiClient.java:159-165
Timestamp: 2025-06-28T02:03:38.693Z
Learning: User thezz9's service (ezcode) targets Korean users exclusively ("찐 한국인밖에 안 옴"), so Korean language hardcoding in commit messages and UI elements is intentional and appropriate for their use case.

Learnt from: thezz9
PR: ezcode-my/backend#75
File: src/main/java/org/ezcode/codetest/application/submission/aop/CodeReviewLockAspect.java:25-41
Timestamp: 2025-06-19T06:37:57.845Z
Learning: User thezz9 tends to skip validation for scenarios they consider unlikely to occur, but is willing to implement defensive programming practices when suggested for code robustness.

Learnt from: thezz9
PR: ezcode-my/backend#114
File: src/main/java/org/ezcode/codetest/infrastructure/github/GitHubApiClient.java:93-96
Timestamp: 2025-06-28T02:04:24.957Z
Learning: User thezz9 sometimes temporarily uses less secure or inconsistent exception handling (like RuntimeException with raw error bodies) for debugging purposes when error messages are being hidden in the normal application flow, but acknowledges this as technical debt and fixes it once debugging is complete.

Learnt from: thezz9
PR: ezcode-my/backend#132
File: src/main/java/org/ezcode/codetest/infrastructure/github/GitHubContentBuilder.java:72-72
Timestamp: 2025-07-02T09:39:31.485Z
Learning: User thezz9 prefers to proceed with breaking changes to path structures when it improves the organization, rather than maintaining backward compatibility or implementing migration strategies.

Learnt from: thezz9
PR: ezcode-my/backend#30
File: src/main/java/org/ezcode/codetest/domain/problem/model/dto/SubmissionData.java:42-53
Timestamp: 2025-06-04T13:12:16.729Z
Learning: 사용자 thezz9는 개발 시 기능적 정확성을 먼저 달성한 후 세부 리팩터링을 나중에 하는 접근 방식을 선호한다. 테스트 단계에서는 하드코딩된 값도 허용한다.

@thezz9 thezz9 merged commit 6ae605a into dev Jul 26, 2025
2 checks passed
@thezz9 thezz9 deleted the refactor/submission-dto branch July 26, 2025 12:08
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

enhancement New feature or request

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants