Skip to content

Dev#320

Merged
hyuuuun merged 4 commits into
mainfrom
dev
Mar 23, 2026
Merged

Dev#320
hyuuuun merged 4 commits into
mainfrom
dev

Conversation

@hyuuuun
Copy link
Copy Markdown
Contributor

@hyuuuun hyuuuun commented Mar 23, 2026

개요

관련 BackLog

Resolves: (Backlog Number, ...)

PR 유형

  • 새로운 기능 추가
  • 버그 수정
  • CSS 등 사용자 UI 디자인 변경
  • 코드에 영향을 주지 않는 변경사항(오타 수정, 탭 사이즈 변경, 변수명 변경)
  • 코드 리팩토링
  • 주석 추가 및 수정
  • 문서 수정
  • 테스트 추가, 테스트 리팩토링
  • 빌드 부분 혹은 패키지 매니저 수정
  • 파일 혹은 폴더명 수정
  • 파일 혹은 폴더 삭제

PR Checklist

  • 커밋 메시지 컨벤션에 맞게 작성했습니다.
  • 변경 사항에 대한 테스트를 했습니다.(버그 수정/기능에 대한 테스트).

Summary by CodeRabbit

  • New Features

    • Added capability to automatically restore visibility for family lines when disabling private permissions
  • Chores

    • Enhanced deployment workflow with separate release and traffic deployment steps, including conditional logic to optionally skip traffic deployment
  • Tests

    • Added comprehensive test coverage for privacy permission disable scenarios

@hyuuuun hyuuuun requested a review from hyeonRS March 23, 2026 13:41
@hyuuuun hyuuuun self-assigned this Mar 23, 2026
@coderabbitai
Copy link
Copy Markdown

coderabbitai Bot commented Mar 23, 2026

Caution

Review failed

Pull request was closed or merged during review

📝 Walkthrough

Walkthrough

The changes introduce a privacy restoration mechanism where disabling a member's privacy permission (permissionId == 2) automatically restores the affected family line(s) to public visibility. Updates span GitHub Actions workflow configuration (separating release and traffic deployments), new mapper methods for bulk public-state restoration, service integration logic, MyBatis SQL statements, and comprehensive unit test coverage.

Changes

Cohort / File(s) Summary
GitHub Actions Deployment
.github/workflows/gradle.yml
Split sequential CodeDeploy deployments into separate steps: release deployment always executes, traffic deployment conditionally runs based on SKIP_TRAFFIC_DEPLOY flag.
Permission Mapper Interface
src/main/java/com/pooli/permission/mapper/FamilyLineMapper.java
Added two new mapper method declarations: forcePublicByLineId(Long) for single line and forcePublicByLineIds(List<Long>) for bulk operations to restore public visibility.
Service Implementation
src/main/java/com/pooli/permission/service/MemberPermissionServiceImpl.java
Integrated calls to new FamilyLineMapper methods in both updateMemberPermission and bulkUpdateMemberPermissions when privacy permission is disabled; only affected lines are processed in bulk case.
MyBatis Mapper XML
src/main/resources/mapper/permission/FamilyLineMapper.xml
Added two <update> statements to set is_public = TRUE and updated_at = NOW() for single and bulk line restoration scenarios.
Service Unit Tests
src/test/java/com/pooli/permission/service/MemberPermissionServiceImplTest.java
Added four new tests verifying privacy permission disable triggers public restoration calls for both single and bulk updates; added complementary tests confirming other permission IDs do not trigger restoration; updated @DisplayName annotations for clarity.

Sequence Diagram

sequenceDiagram
    actor Client
    participant Service as MemberPermissionServiceImpl
    participant Mapper as FamilyLineMapper
    participant DB as Database

    Client->>Service: updateMemberPermission(permissionId=2, isEnable=false, lineId)
    Service->>Service: permissionLineMapper.upsert(...)
    
    alt permissionId == 2 AND isEnable == false
        Service->>Mapper: forcePublicByLineId(lineId)
        Mapper->>DB: UPDATE FAMILY_LINE SET is_public=TRUE WHERE line_id=?
        DB-->>Mapper: Success
        Mapper-->>Service: void
    else other permissions
        Note over Service: No restoration
    end
    
    Service-->>Client: Updated permission state
Loading

Estimated code review effort

🎯 3 (Moderate) | ⏱️ ~30-35 minutes

Possibly related PRs

  • Dev to main #190: Modifies GitHub Actions gradle.yml CodeDeploy deployment configuration with similar parameter/step restructuring.
  • Dev to main #177: Updates the same gradle.yml workflow file to separate release and traffic deployment steps.

Suggested reviewers

  • hyeonRS
  • pjh813

Poem

🐰 When privacy dims but lines must shine,
Our mapper hops and draws the line—
False becomes true, is_public restored,
Bulk or single, permissions poured!
A rabbit's logic, clean and bright. ✨

🚥 Pre-merge checks | ✅ 1 | ❌ 2

❌ Failed checks (2 warnings)

Check name Status Explanation Resolution
Title check ⚠️ Warning The title 'Dev' is generic and vague, failing to convey any meaningful information about the changeset's primary purpose or content. Replace with a descriptive title that captures the main change, such as 'Fix isPublic restoration for family lines and traffic deployment skip logic' or similar.
Docstring Coverage ⚠️ Warning Docstring coverage is 31.25% which is insufficient. The required threshold is 80.00%. Write docstrings for the functions missing them to satisfy the coverage threshold.
✅ Passed checks (1 passed)
Check name Status Explanation
Description Check ✅ Passed Check skipped - CodeRabbit’s high-level summary is enabled.

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

✨ Finishing Touches
📝 Generate docstrings
  • Create stacked PR
  • Commit on current branch
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Commit unit tests in branch dev

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.

@hyuuuun hyuuuun merged commit 8207e87 into main Mar 23, 2026
4 of 5 checks passed
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.

3 participants