-
Notifications
You must be signed in to change notification settings - Fork 1
prod #392
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
prod #392
Conversation
refactor: 1026 수험 번호 배치 시간 재수정
Summary of ChangesHello @chominju02, 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! This pull request modifies the execution schedule of a specific cron job, Highlights
Using Gemini Code AssistThe 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
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 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
|
|
Important Review skippedAuto reviews are disabled on base/target branches other than the default branch. Please check the settings in the CodeRabbit UI or the You can disable this status message by setting the ✨ Finishing touches🧪 Generate unit tests (beta)
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. Comment |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Code Review
안녕하세요. PR 리뷰입니다.
이번 변경은 ExamNumberGenerationJobRound2 잡의 실행 시간을 오전 3시에서 오전 8시로 변경하는 내용이네요.
코드 변경 자체는 간단하지만, 관련 코드에 몇 가지 개선할 점이 보여 의견을 남깁니다. cron 표현식이나 시험 날짜와 같은 설정 값들을 코드에 직접 하드코딩하기보다 외부 설정 파일(application.yml 등)로 분리하면 유지보수성이 크게 향상될 것입니다. 특히 운영 중 스케줄 변경이 필요할 때 재배포 없이 대응할 수 있어 유용합니다.
자세한 내용은 코드 리뷰 코멘트를 참고해주세요. 또한, PR 제목과 설명을 조금 더 자세히 작성해주시면 다른 팀원들이 변경 내용을 파악하는 데 큰 도움이 될 것입니다.
|
|
||
| @Slf4j | ||
| @CronJob(cron = "0 0 3 22 10 ?", name = "examNumberGeneratorJob_20251026") | ||
| @CronJob(cron = "0 0 8 22 10 ?", name = "examNumberGeneratorJob_20251026") |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
cron 표현식을 코드에 하드코딩하면 스케줄 변경 시 코드를 수정하고 다시 배포해야 하는 번거로움이 있습니다. 운영 환경에서는 유연성이 떨어질 수 있습니다.
이 값을 application.yml과 같은 설정 파일로 분리하는 것을 고려해 보세요.
application.yml:
mosu:
job:
exam-number-generation-round2:
cron: "0 0 8 22 10 ?"그리고 CronJob 어노테이션에서 이 값을 참조하도록 합니다.
@CronJob(cron = "${mosu.job.exam-number-generation-round2.cron}", name = "examNumberGeneratorJob_20251026")이를 위해서는 QuartzAutoRegisterConfig에서 cron 표현식을 읽을 때 Spring의 Environment를 사용하여 프로퍼티 플레이스홀더(${...})를 해석하도록 수정이 필요할 수 있습니다.
관련하여, 22행의 examDate와 ExamNumberGenerationJobRound1과의 코드 중복도 유사한 방식으로 개선할 수 있습니다. 이렇게 하면 향후 새로운 시험 일정을 추가할 때 더 관리하기 쉬운 구조가 될 것입니다.
✨ 구현한 기능
📢 논의하고 싶은 내용
🎸 기타