Skip to content

Comments

[FEAT] payment 서버 초기화 설정(#285)#287

Merged
redblackblossom merged 4 commits intomainfrom
feat/#285/payment_init
Feb 13, 2026
Merged

[FEAT] payment 서버 초기화 설정(#285)#287
redblackblossom merged 4 commits intomainfrom
feat/#285/payment_init

Conversation

@redblackblossom
Copy link
Contributor

@redblackblossom redblackblossom commented Feb 13, 2026

📌 관련 이슈

✨ PR 세부 내용

결제 서버를 독립 모듈로 추가하고, payment 모듈 기준으로 CI/CD 및 커버리지 수집이 동작하도록 파이프라인을 확장했
습니다

  1. payment 모듈 초기 구성
  • settings.gradlepayment 포함
  1. CI 로직 작성
  • .github/workflows/ci.yml
    • 변경 감지 대상에 payment/** 추가
    • test-payment job 추가
  • .github/workflows/test-payment.yml 신규
    • :payment:test 실행
  1. CD 로직 작성
  • .github/workflows/cd.yml
    • 변경 감지 대상에 payment/** 추가
    • deploy-payment job 추가
  • .github/workflows/deploy-payment.yml 신규
    • payment 이미지 빌드/푸시 (sha/latest 태그)
  1. 커버리지/문서 반영
  • codecov.ymlpayment flag (carryforward: true) 추가
  • readme.md에 Payment 커버리지 배지 추가

Summary by CodeRabbit

릴리스 노트

  • 새로운 기능

    • 결제 서비스 모듈이 추가되었습니다.
    • 결제 기능에 대한 Docker 컨테이너 지원이 추가되었습니다.
  • Chores

    • 결제 모듈에 대한 자동화된 테스트 및 배포 파이프라인이 구축되었습니다.
    • 코드 커버리지 추적에 결제 모듈이 포함되었습니다.

@redblackblossom redblackblossom self-assigned this Feb 13, 2026
@redblackblossom redblackblossom linked an issue Feb 13, 2026 that may be closed by this pull request
@coderabbitai
Copy link

coderabbitai bot commented Feb 13, 2026

📝 Walkthrough

Walkthrough

결제 모듈을 위한 새로운 Spring Boot 서버 모듈을 추가하고, CI/CD 파이프라인에 결제 모듈 빌드, 테스트 및 배포 작업을 통합합니다. Dockerfile, Gradle 빌드 설정, 테스트 워크플로우 및 GitHub Actions 워크플로우 구성을 포함합니다.

Changes

Cohort / File(s) Summary
CI/CD 워크플로우 설정
.github/workflows/cd.yml, .github/workflows/ci.yml
detect-changes 작업에 payment 경로 필터 추가, payment 출력 선언, payment 변경 감지 시 실행되는 test-payment, deploy-payment 작업 조건 추가
배포 및 테스트 워크플로우
.github/workflows/deploy-payment.yml, .github/workflows/test-payment.yml
결제 모듈을 위한 새 워크플로우: 배포는 Docker 이미지 빌드 및 푸시, 테스트는 JUnit 테스트 실행 및 코드 커버리지 리포팅
결제 모듈 스캐폴딩
payment/Dockerfile, payment/build.gradle, payment/src/main/java/net/catsnap/CatsnapPayment/CatsnapPaymentApplication.java, payment/src/test/java/net/catsnap/CatsnapPayment/CatsnapPaymentApplicationTests.java
Spring Boot 3.5.10 기반 결제 서버 모듈: 다단계 Docker 빌드, Gradle 설정(JaCoCo 포함), 기본 Spring Boot 애플리케이션 클래스 및 테스트 클래스
구성 및 문서 업데이트
codecov.yml, readme.md, settings.gradle
Codecov에 payment 모듈 플래그 추가, readme에 결제 모듈 커버리지 배지 추가, gradle 설정에 payment 모듈 포함

Estimated code review effort

🎯 3 (Moderate) | ⏱️ ~20 분

Possibly related PRs

Suggested labels

✨feature, 👷cicd

🚥 Pre-merge checks | ✅ 4 | ❌ 2
❌ Failed checks (2 warnings)
Check name Status Explanation Resolution
Docstring Coverage ⚠️ Warning Docstring coverage is 0.00% which is insufficient. The required threshold is 80.00%. Write docstrings for the functions missing them to satisfy the coverage threshold.
Merge Conflict Detection ⚠️ Warning ⚠️ Unable to check for merge conflicts: Invalid branch name format
✅ Passed checks (4 passed)
Check name Status Explanation
Title check ✅ Passed 제목이 변경 사항의 핵심을 명확하게 반영하고 있으며, payment 서버 초기화 설정이 PR의 주요 목표와 일치합니다.
Description check ✅ Passed PR 설명이 제공된 템플릿 구조를 따르고, 관련 이슈(#285)를 명시하며, 상세한 변경 사항을 4개 섹션으로 체계적으로 기술합니다.
Linked Issues check ✅ Passed PR은 이슈 #285의 요구사항을 완전히 충족합니다: payment 모듈을 독립적인 서버 모듈로 생성하고, 저장소에 초기화된 모듈을 제공합니다.
Out of Scope Changes check ✅ Passed 모든 변경 사항이 이슈 #285의 요구사항(payment 모듈 초기화) 범위 내에 있으며, 범위를 벗어난 변경 사항은 없습니다.

✏️ Tip: You can configure your own custom pre-merge checks in the settings.

✨ Finishing touches
  • 📝 Generate docstrings
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Post copyable unit tests in a comment
  • Commit unit tests in branch feat/#285/payment_init
⚔️ Resolve merge conflicts (beta)
  • Auto-commit resolved conflicts to branch feat/#285/payment_init
  • Create stacked PR with resolved conflicts
  • Post resolved changes as copyable diffs in a comment

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

Comment @coderabbitai help to get the list of available commands and usage tips.

@github-actions
Copy link

Test Results (authorization-shared)

75 tests   75 ✅  0s ⏱️
19 suites   0 💤
19 files     0 ❌

Results for commit a2bb9b7.

@github-actions
Copy link

Test Results (event-schema-shared)

35 tests   35 ✅  0s ⏱️
 6 suites   0 💤
 6 files     0 ❌

Results for commit a2bb9b7.

@codecov
Copy link

codecov bot commented Feb 13, 2026

Codecov Report

❌ Patch coverage is 33.33333% with 2 lines in your changes missing coverage. Please review.

Files with missing lines Patch % Lines
...snap/CatsnapPayment/CatsnapPaymentApplication.java 33.33% 2 Missing ⚠️

📢 Thoughts on this report? Let us know!

@github-actions
Copy link

Test Results (gateway)

54 tests   54 ✅  3s ⏱️
24 suites   0 💤
24 files     0 ❌

Results for commit a2bb9b7.

@github-actions
Copy link

Test Results (payment)

1 tests   1 ✅  0s ⏱️
1 suites  0 💤
1 files    0 ❌

Results for commit a2bb9b7.

@github-actions
Copy link

Test Results (mono)

41 tests   41 ✅  4s ⏱️
16 suites   0 💤
16 files     0 ❌

Results for commit a2bb9b7.

@github-actions
Copy link

Test Results (reservation)

337 tests   337 ✅  8s ⏱️
 53 suites    0 💤
 53 files      0 ❌

Results for commit a2bb9b7.

@github-actions
Copy link

Test Results (authentication)

196 tests   196 ✅  14s ⏱️
 60 suites    0 💤
 60 files      0 ❌

Results for commit a2bb9b7.

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: 6

🤖 Fix all issues with AI agents
In @.github/workflows/test-payment.yml:
- Around line 19-27: The workflow uses the cache action with an inconsistent
version tag; search for the "uses: actions/cache@" occurrences across all
workflow YAMLs and standardize them to the chosen version (e.g., replace "uses:
actions/cache@v3" with "uses: actions/cache@v5.0.3"); update the line in this
file where "uses: actions/cache@v3" appears and make the same replacement in
every other workflow so all workflows use the identical actions/cache version.

In `@payment/build.gradle`:
- Around line 26-40: There are two jacocoTestReport blocks; merge them into a
single jacocoTestReport declaration so the reports configuration (html/xml/csv)
and the finalizedBy jacocoTestCoverageVerification are defined together, and
remove the duplicate block; ensure the test task still has finalizedBy
jacocoTestReport so tests trigger the report generation (referencing
jacocoTestReport, test, and jacocoTestCoverageVerification).
- Around line 22-24: The jacoco block currently sets toolVersion = "0.8.7";
update the jacoco toolVersion to "0.8.12" in this build.gradle (change the
jacoco { toolVersion = "0.8.7" } entry) and ensure you apply the same 0.8.12
version consistently across all modules (payment, reservation, gateway,
authentication, mono, and any shared modules) so the project uses a single
Jacoco version compatible with Java 17.

In `@payment/Dockerfile`:
- Around line 1-44: Add a HEALTHCHECK to the Dockerfile that probes the Spring
Boot Actuator health endpoint (e.g., GET /actuator/health) against the running
jar (app.jar) so container orchestrators can detect unhealthy containers; update
the runtime image to install a small HTTP client (curl or wget) or switch to a
shell-built probe, ensure the application includes spring-boot-starter-actuator
and the health endpoint is enabled, and run the probe as the existing runtime
user (appuser) or use appropriate permissions so the check succeeds; place the
HEALTHCHECK before or after EXPOSE 8080 and ensure it uses a sensible
interval/retries/start-period for production.
- Line 36: The Docker COPY uses a glob that can match multiple JARs (COPY
--from=builder /app/payment/build/libs/*.jar /app/app.jar), so modify the
payment Gradle build to prevent producing both the executable and plain jars by
adding jar { enabled = false } in the payment module's build script; insert the
jar { enabled = false } block right after the dependencies block in the payment
build.gradle so only the single boot JAR is produced and the COPY target
resolves to one file.

In
`@payment/src/main/java/net/catsnap/CatsnapPayment/CatsnapPaymentApplication.java`:
- Line 1: The package declaration uses mixed case (package
net.catsnap.CatsnapPayment) which violates Java package naming conventions;
update the package to all-lowercase (e.g., net.catsnap.catsnappayment) in
CatsnapPaymentApplication and in all source files that declare or import
net.catsnap.CatsnapPayment, rename the corresponding directory/package folder to
match the lowercase name, and propagate the same lowercase rename consistently
for the other modules mentioned (CatsnapAuthorization, CatsnapGateway) including
any build configs, import statements, and module references so compiles and
imports remain correct.

Comment on lines +22 to +24
jacoco {
toolVersion = "0.8.7"
}
Copy link

Choose a reason for hiding this comment

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

🧹 Nitpick | 🔵 Trivial

🧩 Analysis chain

🏁 Script executed:

#!/bin/bash
# Find all Jacoco toolVersion declarations across modules
rg "toolVersion" --glob "*/build.gradle" -n -B 1 -A 1

Repository: CUKCatSnap/CUKCATSNAP_Server

Length of output: 950


🌐 Web query:

Jacoco 0.8.7 Java 17 compatibility requirements

💡 Result:

JaCoCo 0.8.7 has only experimental compatibility with Java 17:

  • Java 17 class files: 0.8.7 adds experimental support for Java 17 class files (i.e., analyzing/reporting/instrumenting bytecode compiled for Java 17 is not “officially supported” yet). Official Java 17 support comes in JaCoCo 0.8.8. [1][2]
  • Minimum runtime to run JaCoCo components: JaCoCo’s minimum required Java runtime version is Java 5 (per JaCoCo maintainer; applies to all releases). [2]
  • If you’re using the Maven plugin: the JaCoCo Maven plugin requires Maven 3+, Java 8+ for the Maven runtime, and Java 5+ for the test executor (the JVM running tests with the agent). [3]

Practical takeaway: If you need dependable Java 17 coverage, use JaCoCo ≥ 0.8.8 (0.8.7 is “experimental” for Java 17). [1]

Sources: [1] JaCoCo change history / 0.8.7–0.8.8 notes, [2] JaCoCo users list (maintainer reply referencing 0.8.7 + runtime minimum), [3] JaCoCo Maven plugin prerequisites.


Jacoco 0.8.7은 Java 17 호환성을 위해 0.8.12로 업그레이드 권장됩니다.

0.8.7은 Java 17에 대한 실험적 지원만 제공하며, 공식적인 지원은 0.8.8 이상에서 시작됩니다. 현재 프로젝트에서 일관성 없게 0.8.7 (payment, reservation, gateway, authentication, mono)과 0.8.12 (event-schema-shared, authorization-shared)가 혼용 중이므로, 모든 모듈을 0.8.12로 통일하는 것을 권장합니다.

🤖 Prompt for AI Agents
In `@payment/build.gradle` around lines 22 - 24, The jacoco block currently sets
toolVersion = "0.8.7"; update the jacoco toolVersion to "0.8.12" in this
build.gradle (change the jacoco { toolVersion = "0.8.7" } entry) and ensure you
apply the same 0.8.12 version consistently across all modules (payment,
reservation, gateway, authentication, mono, and any shared modules) so the
project uses a single Jacoco version compatible with Java 17.

Copy link
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

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

Pull request overview

This PR initializes the payment module as an independent microservice, setting up its basic structure along with complete CI/CD pipelines for automated testing and deployment.

Changes:

  • Added payment module with Spring Boot 3.5.10, including basic application structure and context load test
  • Configured CI workflow to automatically test payment module on relevant file changes
  • Configured CD workflow to build and deploy payment service Docker image to Docker Hub
  • Added payment module to Codecov with carryforward configuration for coverage tracking

Reviewed changes

Copilot reviewed 14 out of 15 changed files in this pull request and generated 3 comments.

Show a summary per file
File Description
settings.gradle Added payment module to project structure
readme.md Added payment module to coverage badges table
payment/build.gradle Gradle build configuration for payment service with Jacoco coverage
payment/Dockerfile Multi-stage Docker build for payment service
payment/src/main/java/net/catsnap/CatsnapPayment/CatsnapPaymentApplication.java Spring Boot main application class
payment/src/test/java/net/catsnap/CatsnapPayment/CatsnapPaymentApplicationTests.java Basic context load test
payment/gradlew, payment/gradlew.bat Gradle wrapper scripts
payment/gradle/wrapper/* Gradle wrapper configuration files (Gradle 8.14.4)
.github/workflows/ci.yml Updated to detect payment changes and trigger payment tests
.github/workflows/test-payment.yml New workflow for running payment module tests with coverage upload
.github/workflows/cd.yml Updated to detect payment changes and trigger deployment
.github/workflows/deploy-payment.yml New workflow for building and pushing payment Docker image
codecov.yml Added payment flag configuration with carryforward enabled

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Comment on lines +48 to +50
tasks.named('test') {
useJUnitPlatform()
}
Copy link

Copilot AI Feb 13, 2026

Choose a reason for hiding this comment

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

The build.gradle is missing the jar configuration that is present in other modules. Other modules in the codebase include 'jar { enabled = false }' to prevent the creation of plain jar files (only bootJar is created). Consider adding this configuration for consistency with other modules like reservation and authentication.

Copilot uses AI. Check for mistakes.
Comment on lines +1 to +7
distributionBase=GRADLE_USER_HOME
distributionPath=wrapper/dists
distributionUrl=https\://services.gradle.org/distributions/gradle-8.14.4-bin.zip
networkTimeout=10000
validateDistributionUrl=true
zipStoreBase=GRADLE_USER_HOME
zipStorePath=wrapper/dists
Copy link

Copilot AI Feb 13, 2026

Choose a reason for hiding this comment

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

The payment module includes its own gradle wrapper directory with Gradle 8.14.4, while the root project uses Gradle 9.2.1. Other modules (reservation, authentication) don't have their own gradle wrapper directories and rely on the root gradle wrapper. For consistency with the codebase, consider removing the payment-specific gradle wrapper directory (payment/gradle/) and using the root gradle wrapper like other modules. The Dockerfile already copies the root gradle directory, so these local wrapper files may not be used and could cause confusion.

Copilot uses AI. Check for mistakes.
@redblackblossom redblackblossom merged commit 5433e1d into main Feb 13, 2026
29 checks passed
@redblackblossom redblackblossom deleted the feat/#285/payment_init branch February 13, 2026 02:09
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

[FEAT] 결제 모듈 초기화

1 participant