Skip to content

feat: AAB 용량 최적화 — 54.5MB → 27.4MB (49.6% 감소)#380

Merged
unam98 merged 1 commit intodevelopfrom
feature/reduce-aab-size
Apr 4, 2026
Merged

feat: AAB 용량 최적화 — 54.5MB → 27.4MB (49.6% 감소)#380
unam98 merged 1 commit intodevelopfrom
feature/reduce-aab-size

Conversation

@unam98
Copy link
Copy Markdown
Collaborator

@unam98 unam98 commented Apr 4, 2026

작업 배경

  • R8 난독화(feat: R8 난독화 및 리소스 축소 활성화 #379) 적용 후에도 AAB 46.8MB로 큰 상태 → 분석 결과 75%가 Naver Map SDK 네이티브 라이브러리, 나머지는 미사용 폰트/비효율 이미지
  • ABI 필터링 + 미사용 리소스 정리로 추가 용량 절감

변경 사항

1. ABI 필터링 (app/build.gradle)

  • ndk { abiFilters 'arm64-v8a', 'armeabi-v7a' } 추가
  • x86/x86_64 (에뮬레이터 전용) 제거 → 실 디바이스 99%+ 커버
  • 최신 에뮬레이터(API 28+)는 ARM 바이너리 트랜슬레이션을 지원하므로 에뮬레이터 테스트도 정상 동작

2. 미사용 Pretendard 폰트 제거

  • 삭제: thin, extralight, light, extrabold, black (5개, 6.5MB)
  • 유지: regular, medium, semibold, bold (실제 사용 중인 4개)
  • runnect_font.xml, Type.kt에서 참조 함께 제거

3. 스플래시 PNG → WebP 변환

  • 5개 density PNG (1.2MB) → WebP (103KB)로 변환 (91% 절감)

AAB 용량 변화 (전체 누적)

단계 AAB 용량 절감률
원본 (난독화 전) 54.5 MB
R8 난독화 적용 (#379) 46.8 MB -14%
+ ABI 필터링 + 폰트 + WebP (이 PR) 27.4 MB -49.6% (누적)

영향 범위

  • debug/release 모두 arm64-v8a, armeabi-v7a만 포함
  • UI 변경 없음 — 사용 중인 폰트 4개와 스플래시 이미지는 그대로 유지

Test Plan

  • ./gradlew bundleRelease 빌드 성공
  • AAB 용량 27.4MB 확인
  • 릴리즈 빌드 설치 → 폰트 렌더링 정상 확인 (Regular/Medium/SemiBold/Bold)
  • 스플래시 화면 정상 표시 확인
  • Naver Map 정상 동작 확인
  • arm64-v8a 실 디바이스 테스트

🤖 Generated with Claude Code

- ndk abiFilters를 arm64-v8a, armeabi-v7a로 제한 (x86/x86_64 에뮬레이터 전용 ABI 제거)
- 미사용 Pretendard 폰트 5개 제거 (thin, extralight, light, extrabold, black)
- 스플래시 PNG를 WebP로 변환 (1.2MB → 103KB)
- AAB 용량: 54.5MB → 27.4MB (49.6% 감소, 난독화 포함 누적)
@coderabbitai
Copy link
Copy Markdown

coderabbitai bot commented Apr 4, 2026

📝 Walkthrough

Walkthrough

The pull request restricts native library packaging to specific ARM architectures via NDK abiFilters in the build configuration and removes unused Pretendard font weights (100, 200, 300, 800, 900) from both the font family definition and font resource mappings.

Changes

Cohort / File(s) Summary
Build Configuration
app/build.gradle
Added NDK abiFilters to android.defaultConfig to restrict native library packaging to arm64-v8a and armeabi-v7a architectures.
Font Weight Cleanup
app/src/main/java/com/runnect/runnect/presentation/ui/theme/Type.kt, app/src/main/res/font/runnect_font.xml
Removed declarations for Pretendard font weights: Thin (100), ExtraLight (200), Light (300), ExtraBold (800), and Black (900). Retained Regular, Medium, SemiBold, and Bold weights.

Estimated code review effort

🎯 2 (Simple) | ⏱️ ~8 minutes

Poem

🐰 The rabbit hops through code so clean,
Trimming fonts we've never seen,
ARM architectures, two to keep,
Lightweight builds, not a peep!
Pretendard weights all lean and bright,
Hopping forward—swift and light! 🐾

🚥 Pre-merge checks | ✅ 3
✅ Passed checks (3 passed)
Check name Status Explanation
Title check ✅ Passed The title accurately describes the main objective: AAB size optimization from 54.5MB to 27.4MB (49.6% reduction), which is supported by the changes to build configuration (ABI filtering), font removal, and image conversion.
Docstring Coverage ✅ Passed No functions found in the changed files to evaluate docstring coverage. Skipping docstring coverage check.
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 feature/reduce-aab-size

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.

@unam98
Copy link
Copy Markdown
Collaborator Author

unam98 commented Apr 4, 2026

@coderabbitai review

@coderabbitai
Copy link
Copy Markdown

coderabbitai bot commented Apr 4, 2026

✅ Actions performed

Review triggered.

Note: CodeRabbit is an incremental review system and does not re-review already reviewed commits. This command is applicable only when automatic reviews are paused.

@unam98 unam98 self-assigned this Apr 4, 2026
@unam98 unam98 merged commit 7417e63 into develop Apr 4, 2026
1 of 2 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.

1 participant