Skip to content

리소스 절감 — 한 페이지 요약

본문: resource-optimization-safe-adoption-plan.md

목표: Noisy Neighbor 방지 — Docker cgroups로 컨테이너 격리, Control Plane이 패키지(plan)에 따라 Ansible에 plan_limits 동적 전달.


적용 순서 (기존 시스템 영향 없음)

#항목선행 조건비고
1Redis confRedis 배포 완료maxmemory, allkeys-lru. save/appendonly는 cache DB만 비영속
2Gunicorncommon_site_config/Procfile 경로max_requests 1000, jitter 100, timeout 120
3Docker 제한Ansible/compose플랜별 Soft(Hard)·memswap, plan_limits 동적 적용, OOM 90%·CPU 스로틀 모니터링
4CDN/StaticR2 assets 업로드·assets_base_urlNginx 301 + Cloudflare 캐시. Staging 검증 후
5MariaDB my.cnfmariadb-mycnf-optimization-plan 범위 내만

적용 O / 제외 X

정책적용비고
Redis maxmemory·allkeys-lruOqueue/socketio DB는 appendonly 유지 권장
Gunicorn max-requests·jitterO
Docker 플랜별 limits·OOM 감지O
CDN/Static (R2)O**선행 조건 충족 후
MariaDB my.cnf 튜닝O기존 기획서 참조
ProxySQL·PyPy·D1 하이브리드X별도/장기 검토
Zuplo Edge Cache선택읽기 전용·짧은 TTL API만

플랜별 Docker 제한 (참고)

플랜CPUMemory (Hard)Memory (Soft)
Free0.5512MB~1GB256MB~512MB
Pro1.52GB1GB
Enterprise48GB4GB

Control Plane이 테넌트 생성·업그레이드 시 **plan_limits[user_plan]**을 Ansible에 전달 → 컨테이너 동적 설정. memswap_limit = Hard와 동일 권장.

격리 계층: Edge(Zuplo Rate Limit) → App(Docker cgroups) → DB(Sharding·별도 서버).


관련 기획서

Help