Skip to content

[UPLUS-121] HOTFIX: Trigger job명 수정#39

Merged
arkchive merged 1 commit into
developfrom
feat/UPLUS-121
Jan 26, 2026
Merged

[UPLUS-121] HOTFIX: Trigger job명 수정#39
arkchive merged 1 commit into
developfrom
feat/UPLUS-121

Conversation

@paul0755
Copy link
Copy Markdown
Contributor

🎫 지라 티켓

UPLUS-121


✅ 작업 사항

trigger job명 변환을 안시킨 부분을 수정하였습니다.


📋 체크리스트

  • 코드가 정상적으로 빌드됩니다.
  • 관련 테스트 코드를 작성했습니다.
  • 기존 테스트가 모두 통과합니다.
  • 코드 스타일(Spotless, Checkstyle)을 준수합니다.

⌨ 기타

@paul0755 paul0755 requested a review from arkchive January 26, 2026 09:06
@paul0755 paul0755 self-assigned this Jan 26, 2026
@github-actions github-actions Bot requested a review from arlen02-01 January 26, 2026 09:06
@github-actions github-actions Bot added size/S PR size: S feat 새로운 기능 labels Jan 26, 2026
@gemini-code-assist
Copy link
Copy Markdown
Contributor

Summary of Changes

Hello @paul0755, 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!

이 PR은 배치 작업 트리거 및 스케줄 요청 시 작업명이 올바르게 변환되지 않던 문제를 해결합니다. BatchJobType을 활용하여 원본 작업명을 적절한 "제목" 형식으로 변환하는 로직이 도입되었습니다. 또한, 애플리케이션의 비밀 구성 파일에 주요 환경 변수들의 기본값을 추가하여 다양한 배포 환경에서의 견고성을 향상시켰습니다.

Highlights

  • 배치 작업명 변환 로직 추가: BatchTriggerClient의 trigger 및 schedule 메서드에서 BatchJobType.getTitleByJobName()을 사용하여 배치 작업명을 적절한 "제목" 형식으로 변환하도록 수정되었습니다.
  • 구성 파일 기본값 설정: application-secret.yml 파일에 URECA_SECRET_KEY, URECA_HASH_KEY, CLOUD_FUNCTION_BASE_URL 환경 변수에 대한 기본값이 추가되어, 환경 변수가 설정되지 않았을 경우의 안정성을 높였습니다.

🧠 New Feature in Public Preview: You can now enable Memory to help Gemini Code Assist learn from your team's feedback. This makes future code reviews more consistent and personalized to your project's style. Click here to enable Memory in your admin console.

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
Copy Markdown
Contributor

@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

이번 PR은 배치 트리거 잡의 이름을 변환하는 로직을 추가하고, 설정 파일에 기본값을 추가하는 수정을 포함하고 있습니다. 코드 변경 사항은 의도한 대로 잘 동작하는 것으로 보입니다. 다만, 몇 가지 개선점을 제안합니다. BatchTriggerClient에서는 파라미터 명을 더 명확하게 변경하고 코드 중복을 줄일 수 있는 부분이 있습니다. 또한, application-secret.yml 파일에 민감한 정보(비밀 키)와 인프라 정보(URL)가 기본값으로 하드코딩되어 있어 보안상 위험이 있습니다. 이에 대한 수정이 필요합니다. 자세한 내용은 각 파일의 주석을 참고해주세요.

Comment on lines 29 to +31
public void trigger(String job, String invMonth) {

String title = BatchJobType.getTitleByJobName(job);
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

medium

잡 이름 변환 로직이 추가되면서 job 파라미터는 이제 jobName을 나타냅니다. 명확성을 위해 파라미터 이름을 jobName으로 변경하는 것을 고려해 보세요. 이렇게 하면 코드의 가독성이 향상됩니다.

Suggested change
public void trigger(String job, String invMonth) {
String title = BatchJobType.getTitleByJobName(job);
public void trigger(String jobName, String invMonth) {
String title = BatchJobType.getTitleByJobName(jobName);

Comment on lines 52 to +54
public void schedule(String job, String cron) {

String title = BatchJobType.getTitleByJobName(job);
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

medium

여기에서도 job 파라미터 이름을 jobName으로 변경하여 일관성과 명확성을 유지하는 것이 좋습니다. 또한, trigger 메소드와 schedule 메소드에 중복되는 BatchJobType.getTitleByJobName 호출 로직을 별도의 private 헬퍼 메소드로 추출하여 코드 중복을 줄이는 것을 고려해 보세요. 예를 들어:

private String getJobTitle(String jobName) {
    return BatchJobType.getTitleByJobName(jobName);
}
Suggested change
public void schedule(String job, String cron) {
String title = BatchJobType.getTitleByJobName(job);
public void schedule(String jobName, String cron) {
String title = BatchJobType.getTitleByJobName(jobName);

cloud:
function:
base-url: ${CLOUD_FUNCTION_BASE_URL}
base-url: ${CLOUD_FUNCTION_BASE_URL:https://asia-northeast3-telecom-app-dev.cloudfunctions.net/fn-batch-control}
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

medium

개발 환경의 기본 URL이라도 코드에 직접 포함하는 것은 인프라 정보를 노출시킬 수 있습니다. 이 URL도 환경 변수를 통해서만 주입하고, 로컬 개발 환경 설정 가이드에 기본값을 명시하는 방식을 고려해보세요.

    base-url: ${CLOUD_FUNCTION_BASE_URL}

@github-actions github-actions Bot added size/XS PR size: XS and removed size/S PR size: S labels Jan 26, 2026
@4e-um 4e-um deleted a comment from gemini-code-assist Bot Jan 26, 2026
@github-actions
Copy link
Copy Markdown

SonarQube Quality Summary (Community)

Quality Gate PASSED

Branch: feat/UPLUS-121
Compared to: default branch

Issues

  • 🐞 Bugs: 0
  • 🔐 Vulnerabilities: 2
  • 📎 Code Smells: 50

Measures

  • Coverage: 0%
  • Duplication: 0%

🔗 Dashboard: https://sonarqube.swthewhite.store/dashboard?id=api-core&branch=feat/UPLUS-121

Generated automatically by GitHub Actions.

Copy link
Copy Markdown
Contributor

@arkchive arkchive left a comment

Choose a reason for hiding this comment

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

LGTM!

@arkchive arkchive merged commit 5ce21f7 into develop Jan 26, 2026
9 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

feat 새로운 기능 size/XS PR size: XS

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants