Skip to content

feat(configuration): 환경변수 DB 저장 기능 구현 (#36)#37

Open
1210thatman wants to merge 7 commits into
developfrom
feature/36-환경변수-db-저장

Hidden character warning

The head ref may contain hidden characters: "feature/36-\ud658\uacbd\ubcc0\uc218-db-\uc800\uc7a5"
Open

feat(configuration): 환경변수 DB 저장 기능 구현 (#36)#37
1210thatman wants to merge 7 commits into
developfrom
feature/36-환경변수-db-저장

Conversation

@1210thatman
Copy link
Copy Markdown
Contributor

Summary

  • 환경변수를 MySQL DB에 저장하고 중앙에서 관리하는 Configuration 서비스 구현
  • 헥사고날 아키텍처(Domain / Application / Adapter-in / Adapter-out) 패턴 적용
  • 다른 MSA 서비스가 gRPC를 통해 환경변수를 조회할 수 있는 엔드포인트 노출

Related Issue

Change Type

  • New feature

Changes

레이어 파일 설명
contracts configuration.proto gRPC 서비스/메시지 정의
domain EnvironmentVariable.kt, Port interfaces, Commands, Exceptions 도메인 모델 및 포트
application EnvironmentVariableService.kt CRUD 유즈케이스 구현
adapter-out EnvironmentVariableJpaEntity, JpaRepository, PersistenceAdapter MySQL JPA 영속성
adapter-in ConfigurationGrpcService, ConfigurationGrpcServer gRPC 서버 (5개 RPC)
bootstrap application.yaml MySQL/gRPC 포트 설정

gRPC API

RPC 설명
CreateEnvironmentVariable 새 환경변수 등록
GetEnvironmentVariable key로 단건 조회
GetAllEnvironmentVariables 전체 조회
UpdateEnvironmentVariable 기존 환경변수 수정
DeleteEnvironmentVariable 환경변수 삭제

Follow-up Tasks

이 PR 머지 후 아래 후속 작업이 필요합니다.

  • DB 테이블 생성: configuration_db 스키마 및 environment_variable 테이블 생성 (현재 ddl-auto: validate 설정으로 앱 실행 전 수동 생성 필요)
    CREATE DATABASE IF NOT EXISTS configuration_db;
    USE configuration_db;
    CREATE TABLE environment_variable (
        id BIGINT AUTO_INCREMENT PRIMARY KEY,
        env_key VARCHAR(255) NOT NULL UNIQUE,
        env_value TEXT NOT NULL,
        description TEXT
    );
  • 환경변수 주입 설정: DB_USERNAME, DB_PASSWORD, GRPC_PORT 환경변수 인프라 설정
  • 다른 서비스 연동: 타 MSA 서비스에서 gRPC 클라이언트 스텁 연결

Review Focus

  • 헥사고날 아키텍처 레이어 경계 준수 여부
  • gRPC 서버 SmartLifecycle 기반 생명주기 관리 방식
  • 트랜잭션 경계 (Application 레이어에서 관리)

Checklist

  • 기존 아키텍처 패턴(헥사고날) 준수
  • 기존 Bazel 빌드 컨벤션 준수
  • 커밋 컨벤션 준수
  • DB 테이블 생성 (후속 작업)
  • 인프라 환경변수 설정 (후속 작업)

1210thatman and others added 7 commits May 10, 2026 17:01
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
@coderabbitai
Copy link
Copy Markdown

coderabbitai Bot commented May 10, 2026

Important

Review skipped

Auto reviews are limited based on label configuration.

🏷️ Required labels (at least one) (1)
  • ready-for-review
🚫 Excluded labels (none allowed) (2)
  • wip
  • do-not-review

Please check the settings in the CodeRabbit UI or the .coderabbit.yaml file in this repository. To trigger a single review, invoke the @coderabbitai review command.

⚙️ Run configuration

Configuration used: Path: .coderabbit.yaml

Review profile: ASSERTIVE

Plan: Pro

Run ID: 720d9056-b3f0-4c0f-a451-ecc1c768fac6

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

Use the checkbox below for a quick retry:

  • 🔍 Trigger review
✨ Finishing Touches
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Commit unit tests in branch feature/36-환경변수-db-저장
  • 🛠️ cleanup stale imports: Commit on current branch
  • 🛠️ cleanup stale imports: Create PR
  • 🛠️ harden error messages: Commit on current branch
  • 🛠️ harden error messages: Create PR
  • 🛠️ test clarity pass: Commit on current branch
  • 🛠️ test clarity pass: Create PR

Tip

💬 Introducing Slack Agent: The best way for teams to turn conversations into code.

Slack Agent is built on CodeRabbit's deep understanding of your code, so your team can collaborate across the entire SDLC without losing context.

  • Generate code and open pull requests
  • Plan features and break down work
  • Investigate incidents and troubleshoot customer tickets together
  • Automate recurring tasks and respond to alerts with triggers
  • Summarize progress and report instantly

Built for teams:

  • Shared memory across your entire org—no repeating context
  • Per-thread sandboxes to safely plan and execute work
  • Governance built-in—scoped access, auditability, and budget controls

One agent for your entire SDLC. Right inside Slack.

👉 Get started


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.

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.

환경변수 DB 저장 기능 구현

2 participants