KCY-Fit-a-Pet / fit-a-pet-server

๐Ÿ• ๋ฐ˜๋ ค๋™๋ฌผ ์ผ€์–ด ์„œ๋น„์Šค Fit a Pet Backend Repository ์ž…๋‹ˆ๋‹ค.

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Fit a Pet

๊น€์ตœ์–‘ ์‚ฌ์ด๋“œ ํ”„๋กœ์ ํŠธ FitaPet ๋ฐฑ์—”๋“œ Repository ์ž…๋‹ˆ๋‹ค.

[๊ฐœ๋ฐœ ๊ธฐ๋ก]

[ Contents ]

Version Control

Version # Revision Date Description Author
v0.0.1 2023.10.1 ํ”„๋กœ์ ํŠธ ๊ธฐ๋ณธ ๊ธฐ๋Šฅ ๊ตฌํ˜„ ๋ฐ ๋ฐฐํฌ ์–‘์žฌ์„œ
v0.0.2 2024.02.17 ๋ฉ€ํ‹ฐ ๋ชจ๋“ˆํ™” ์•„ํ‚คํ…์ฒ˜ ์ถ”๊ฐ€ ์–‘์žฌ์„œ

Dev Environment

  • IntelliJ 2023.1.2
  • Postman 10.18.9
  • GitHub
  • Windows 11
  • Notion

Tech Stack

Framework & Library

  • JDK 17
  • SpringBoot 3.1.0
  • SpringBoot Security
  • Spring Data JPA
  • Spring Doc Open API
  • Lombok
  • JUnit5
  • jjwt 0.11.5
  • httpclient 4.5.14 & httpclient5 5.1.4

Build tool

  • Gradle

Database

  • MySQL8
  • Redis

Infra

  • AWS EC2 (for Build Server)
  • Docker & Docker-compose
  • Jenkins
  • GitHub Todo bot
  • GitHub Action
  • Kakao Talk
  • Naver Cloud Platform Server (for WAS)
  • Naver Cloud Platform Cloud DB for Redis
  • Naver Cloud Platform Object Storage
  • Naver Cloud Platform Simple & Easy Notification Service
  • Naver Cloud Platform API Gateway & Cloud Functions
  • Goorm IDE (for DB Server)

Project Check List

  • ์‹ค์ œ ์„œ๋น„์Šค๋ฅผ ๊ณต๊ฐœ์ ์œผ๋กœ ๋ฐฐํฌํ•˜๊ณ  ์šด์˜ํ•˜๋Š” ๊ฒฝํ—˜์„ ํ•ด๋ณด์•˜๋‹ค.
  • ์œ ์ €์˜ ํ”ผ๋“œ๋ฐฑ์— ๋”ฐ๋ผ ์„ฑ๋Šฅ/์‚ฌ์šฉ์„ฑ์„ ๊ฐœ์„ ํ•˜๊ณ  ์‹ ๊ทœ ๊ธฐ๋Šฅ์„ ์ถ”๊ฐ€ํ•ด๋ณด์•˜๋‹ค.
  • ๋ฐœ๊ฒฌ๋˜๋Š” ๋ฒ„๊ทธ์™€ ๊ฐœ์„ ์‚ฌํ•ญ๋“ค์„ ์ •๋ฆฌํ•˜๊ณ  ์Œ“์ธ ์ด์Šˆ๋“ค์„ ์ฒด๊ณ„์ ์œผ๋กœ ๊ด€๋ฆฌํ•ด๋ณด์•˜๋‹ค.
  • ์ฝ”๋“œ๋ฅผ ์ง€์†์ ์œผ๋กœ ๋ฆฌํŒฉํ† ๋งํ•˜๊ณ  ๋””์ž์ธ ํŒจํ„ด์„ ์ ์šฉํ•ด๋ณด์•˜๋‹ค.
  • ์œ„์˜ ์‹œ๋„์—์„œ ๋” ์ข‹์€ ์„ค๊ณ„์™€ ๋” ๋น ๋ฅธ ๊ฐœ๋ฐœ ์‚ฌ์ด์˜ ํŠธ๋ ˆ์ด๋“œ ์˜คํ”„๋ฅผ ๊ณ ๋ฏผํ•ด๋ณธ ์ ์ด ์žˆ๋‹ค.
  • ๋ฐ˜๋ณต๋˜๋Š” ์ˆ˜์ •๊ณผ ๋ฐฐํฌ์— ์ˆ˜๋ฐ˜๋˜๋Š” ์ž‘์—…๋“ค์„ ์ž๋™ํ™” ํ•ด๋ณด์•˜๋‹ค.
  • ์–ธ์–ด๋‚˜ ํ”„๋ ˆ์ž„์›Œํฌ๋งŒ์œผ๋กœ ๊ตฌํ˜„ํ•  ์ˆ˜ ์—†๋Š” ๊ฒƒ๋“ค์„ ์ง์ ‘ ๊ตฌํ˜„ํ•ด๋ณด์•˜๋‹ค.
  • ๋‚ด๊ฐ€ ์‚ฌ์šฉํ•œ ๋ผ์ด๋ธŒ๋Ÿฌ๋ฆฌ๋‚˜ ํ”„๋ ˆ์ž„ ์›Œํฌ์˜ ํ•œ๊ณ„๋ฅผ ๋Š๋ผ๊ณ  ๊ฐœ์„ ํ•ด๋ณด์•˜๋‹ค.
  • ์ฝ”๋“œ๋‚˜ ์ œํ’ˆ์˜ ํ€„๋ฆฌํ‹ฐ๋ฅผ ์œ ์ง€ํ•˜๊ธฐ ์œ„ํ•œ ๋ถ„์„ํˆด์ด๋‚˜ ํ…Œ์ŠคํŠธ ํˆด์„ ๋„์ž…ํ•ด๋ณด์•˜๋‹ค.
  • ํƒ€์ธ๊ณผ์˜ ํ˜‘์—…์„ ํšจ์œจ์ ์œผ๋กœ ํ•˜๊ธฐ ์œ„ํ•œ ๊ณ ๋ฏผ์„ ํ•ด๋ณด์•˜๋‹ค.

System Architecture

WAS Architecture

  • WAS Server ๋‚ด๋ถ€์— Nginx๋ฅผ ํ†ตํ•ด Reverse Proxy๋ฅผ ๊ตฌํ˜„ํ–ˆ์Šต๋‹ˆ๋‹ค.

Multi Module Architecture

  • Multi Module Architecture๋ฅผ ์ ์šฉํ•˜์—ฌ ๊ฐ ๋ชจ๋“ˆ๋ณ„๋กœ ๋ถ„๋ฆฌํ•˜์—ฌ ๊ฐœ๋ฐœํ•˜๊ณ , ๋นŒ๋“œ ๋ฐ ๋ฐฐํฌ๋ฅผ ์ง„ํ–‰ํ•˜๊ณ  ์žˆ์Šต๋‹ˆ๋‹ค.
  • ๊ฐ ๋ชจ๋“ˆ๋ณ„๋กœ ๋‹ด๋‹นํ•˜๋Š” ์—ญํ• ์„ ๋ถ„๋ฆฌํ•˜์—ฌ ๊ฐœ๋ฐœํ•˜๊ณ  ์žˆ์Šต๋‹ˆ๋‹ค.
  • ๊ฐ ๋ชจ๋“ˆ์— ๋Œ€ํ•œ Convention์€ ๋‹ค์Œ๊ณผ ๊ฐ™์Šต๋‹ˆ๋‹ค.
    • fitapet-common : ๋…๋ฆฝ์ ์ธ ์˜คํ”ˆ ์†Œ์Šค๋กœ ๋ฐฐํฌ ๊ฐ€๋Šฅํ•œ ์ˆ˜์ค€์˜ ๊ณตํ†ต ๋ชจ๋“ˆ. ๋ชจ๋“  ๋ชจ๋“ˆ์ด ์˜์กดํ•œ๋‹ค.
    • fitapet-infra : ๋ฐ์ดํ„ฐ๋ฒ ์ด์Šค, ์ธํ”„๋ผ์ŠคํŠธ๋Ÿญ์ฒ˜, ํด๋ผ์šฐ๋“œ ์„œ๋น„์Šค์™€ ์—ฐ๋™ํ•˜๋Š” ๋ชจ๋“ˆ. common ๋ชจ๋“ˆ์— ์˜์กดํ•œ๋‹ค.
    • fitapet-domain : ๋„๋ฉ”์ธ ๋กœ์ง์„ ๋‹ด๋‹นํ•˜๋ฉฐ, repository๋ฅผ ๋ณดํ˜ธํ•˜๋Š” ๋ชจ๋“ˆ. common ๋ชจ๋“ˆ์— ์˜์กดํ•œ๋‹ค.
    • fitapet-app-external-api : Client์™€ ์—ฐ๋™ํ•˜๋Š” ์™ธ๋ถ€ API๋ฅผ ๋‹ด๋‹นํ•˜๋Š” ๋ชจ๋“ˆ. common, infra, domain ๋ชจ๋“  ๋ชจ๋“ˆ์— ์˜์กดํ•œ๋‹ค.

ERD

  • ํ˜„์žฌ ๋งŽ์€ ๋ถ€๋ถ„์ด ์ˆ˜์ •๋˜์—ˆ๊ณ , ์•ž์œผ๋กœ๋„ ๊ณ„์† ์ˆ˜์ •๋  ์˜ˆ์ •์ž…๋‹ˆ๋‹ค.

Branch Convention

main โ”€โ”€ develop โ”€โ”€ feature
โ””โ”€โ”€ hotfix
Brach name description
main ๋ฐฐํฌ ์ค‘์ธ ์„œ๋น„์Šค ๋ธŒ๋žœ์น˜
โ€ข ์‹ค์ œ ์„œ๋น„์Šค๊ฐ€ ์ด๋ฃจ์–ด์ง€๋Š” ๋ธŒ๋žœ์น˜์ž…๋‹ˆ๋‹ค.
โ€ข ํ•ด๋‹น ๋ธŒ๋žœ์น˜๋ฅผ ๊ธฐ์ค€์œผ๋กœ develop ๋ธŒ๋žœ์น˜๊ฐ€ ๋ถ„๊ธฐ๋ฉ๋‹ˆ๋‹ค.
โ€ข ๊ธด๊ธ‰ ์ˆ˜์ • ์•ˆ๊ฑด์— ๋Œ€ํ•ด์„œ๋Š” hotfix ๋ธŒ๋žœ์น˜์—์„œ ์ฒ˜๋ฆฌํ•ฉ๋‹ˆ๋‹ค.
develop ์ž‘์—… ๋ธŒ๋žœ์น˜
โ€ข ๊ฐœ๋ฐœ, ํ…Œ์ŠคํŠธ, ๋ฆด๋ฆฌ์ฆˆ ๋“ฑ ๋ฐฐํฌ ์ „ ๋‹จ๊ณ„์˜ ๊ธฐ์ค€์ด ๋˜๋Š” ๋ธŒ๋žœ์น˜์ž…๋‹ˆ๋‹ค.
โ€ข ํ”„๋กœ์ ํŠธ์˜ default ๋ธŒ๋žœ์น˜์ž…๋‹ˆ๋‹ค.
โ€ข ํ•ด๋‹น ๋ธŒ๋žœ์น˜์—์„œ feature ๋ธŒ๋žœ์น˜๊ฐ€ ๋ถ„๊ธฐ๋ฉ๋‹ˆ๋‹ค.
feature ๊ธฐ๋Šฅ ๋‹จ์œ„ ๊ตฌํ˜„
โ€ข ๊ฐœ๋ณ„ ๊ฐœ๋ฐœ์ž๊ฐ€ ๋งก์€ ์ž‘์—…์„ ๊ฐœ๋ฐœํ•˜๋Š” ๋ธŒ๋žœ์น˜์ž…๋‹ˆ๋‹ค.
โ€ข feature/(feature-name)์ฒ˜๋Ÿผ ๋จธ๋ฆฟ๋ง-๊ผฌ๋ฆฟ๋ง(๊ฐœ๋ฐœํ•˜๋Š” ๊ธฐ๋Šฅ)์œผ๋กœ ๋ช…๋ช…ํ•ฉ๋‹ˆ๋‹ค.
โ€ข kebab-case ๋„ค์ด๋ฐ ๊ทœ์น™์„ ์ค€์ˆ˜ํ•ฉ๋‹ˆ๋‹ค.
hotfix ์„œ๋น„์Šค ์ค‘ ๊ธด๊ธ‰ ์ˆ˜์ • ์‚ฌํ•ญ ์ฒ˜๋ฆฌ
โ€ข main์—์„œ ๋ถ„๊ธฐํ•ฉ๋‹ˆ๋‹ค.

Commit Convention

emoji message description
โœจ feat ์ƒˆ๋กœ์šด ๊ธฐ๋Šฅ ์ถ”๊ฐ€, ๊ธฐ์กด ๊ธฐ๋Šฅ์„ ์š”๊ตฌ ์‚ฌํ•ญ์— ๋งž์ถ”์–ด ์ˆ˜์ •
๐Ÿ› fix ๊ธฐ๋Šฅ์— ๋Œ€ํ•œ ๋ฒ„๊ทธ ์ˆ˜์ •
๐Ÿ’š build ๋นŒ๋“œ ๊ด€๋ จ ์ˆ˜์ •
๐Ÿ“Œ chore ํŒจํ‚ค์ง€ ๋งค๋‹ˆ์ € ์ˆ˜์ •, ๊ทธ ์™ธ ๊ธฐํƒ€ ์ˆ˜์ • ex) .gitignore
๐Ÿ‘ท ci CI ๊ด€๋ จ ์„ค์ • ์ˆ˜์ •
๐Ÿ“• docs ๋ฌธ์„œ(์ฃผ์„) ์ˆ˜์ •
๐ŸŽจ style ์ฝ”๋“œ ์Šคํƒ€์ผ, ํฌ๋งทํŒ…์— ๋Œ€ํ•œ ์ˆ˜์ •
โ™ป๏ธ refactor ๊ธฐ๋Šฅ ๋ณ€ํ™”๊ฐ€ ์•„๋‹Œ ์ฝ”๋“œ ๋ฆฌํŒฉํ„ฐ๋ง
โœ… test ํ…Œ์ŠคํŠธ ์ฝ”๋“œ ์ถ”๊ฐ€/์ˆ˜์ •
๐Ÿ”– release ๋ฒ„์ „ ๋ฆด๋ฆฌ์ฆˆ
๐Ÿš‘ hotfix ๊ธด๊ธ‰ ์ˆ˜์ •
๐Ÿ”€ branch ๋ธŒ๋žœ์น˜ ์ถ”๊ฐ€/๋ณ‘ํ•ฉ
ํ† ๊ธ€ ์ ‘๊ธฐ/ํŽผ์น˜๊ธฐ
- [ ] `**feat : ํšŒ์›๊ฐ€์ž… API ๊ตฌํ˜„**`๊ณผ ๊ฐ™์ด `**๋จธ๋ฆฟ๋ง: ๋‚ด์šฉ**` ํ˜•์‹์œผ๋กœ ์ž‘์„ฑํ•ฉ๋‹ˆ๋‹ค. - [ ] refactoring์˜ ๊ฒฝ์šฐ ๊ธฐ๋Šฅ ๋ณ€ํ™” ์—†์ด ๊ตฌ์กฐ ๊ฐœ์„ ์„ ํ•˜๋Š” ๊ฒฝ์šฐ ์‚ฌ์šฉํ•ฉ๋‹ˆ๋‹ค. - [ ] ์—ฌ๋Ÿฌ ์ž‘์—…์„ ๋™์‹œ ์‹คํ–‰ํ•œ ๊ฒฝ์šฐ ํ•œ ์ค„์— ํ•œ ๋‚ด์šฉ์”ฉ ์ž…๋ ฅํ•ฉ๋‹ˆ๋‹ค. ์ˆœ์„œ๋Š” ๋ฉ”์ธ์ด ๋œ ์ž‘์—…์„ ์šฐ์„ ์œผ๋กœ ๋‘ก๋‹ˆ๋‹ค.
    ```
    - โŒ ์ž˜๋ชป๋œ ์˜ˆ์‹œ_1
    feat: ๋ฒ„ํŠผ ์ปดํฌ๋„ŒํŠธ ๊ตฌํ˜„, API ์ค‘๋ณต ์š”์ฒญ ํ˜„์ƒ ํ•ด๊ฒฐ
    
    - โŒ ์ž˜๋ชป๋œ ์˜ˆ์‹œ_2
    feat: ๋ฒ„ํŠผ ์ปดํฌ๋„ŒํŠธ ๊ตฌํ˜„ || fix: API ์ค‘๋ณต ์š”์ฒญ ํ˜„์ƒ ํ•ด๊ฒฐ
    
    - โญ• ์˜ฌ๋ฐ”๋ฅธ ์˜ˆ์‹œ
    feat: ๋ฒ„ํŠผ ์ปดํฌ๋„ŒํŠธ ๊ตฌํ˜„
    fix: API ์ค‘๋ณต ์š”์ฒญ ํ˜„์ƒ ํ•ด๊ฒฐ
    ```

About

๐Ÿ• ๋ฐ˜๋ ค๋™๋ฌผ ์ผ€์–ด ์„œ๋น„์Šค Fit a Pet Backend Repository ์ž…๋‹ˆ๋‹ค.


Languages

Language:Java 99.7%Language:JavaScript 0.2%Language:Dockerfile 0.1%Language:Shell 0.0%