spring-boot-standards
2
总安装量
2
周安装量
#69158
全站排名
安装命令
npx skills add https://github.com/ssiumha/dots --skill spring-boot-standards
Agent 安装分布
opencode
2
gemini-cli
2
claude-code
2
github-copilot
2
codex
2
kimi-cli
2
Skill 文档
Spring Boot Standards
Spring Boot ê¸°ë° API ê°ë°ì íì¤ í¨í´ê³¼ ë² ì¤í¸ íëí°ì¤ë¥¼ ì ê³µí©ëë¤.
íµì¬ ì² í:
- ì¼ê´ë API ìëµ êµ¬ì¡° (ApiResult)
- HTTP ë©ìëë³ ë¡ê¹ ë 벨 íì¤
- ë¤êµì´ ë©ìì§ ì²ë¦¬ (MessageSource)
- ì²´ê³ì ì¸ ìì¸ ì²ë¦¬
Instructions
ìí¬íë¡ì°: ìì² ë¶ì ë° ë¦¬ìì¤ ì í
ì¬ì©ì ìì²ì ë¶ìíì¬ íìí 리ìì¤ë§ ì íì ì¼ë¡ ë¡ëí©ëë¤.
1. í¤ìë 매ì¹
API ìëµ í¨í´ (resources/01-api-response.md)
- “ApiResult”, “ìëµ í¨í´”, “response”
- “ëí¼”, “wrapper”, “ê³µíµ ìëµ”
- “ìë¬ ìëµ”, “ì±ê³µ ìëµ”
ë¡ê¹
íì¤ (resources/02-logging.md)
- “ë¡ê¹ ”, “logging”, “log”
- “ë¡ê·¸ ë 벨”, “log level”
- “debug”, “info”, “warn”, “error”
ë¤êµì´ ë©ìì§ (resources/03-i18n.md)
- “i18n”, “ë¤êµì´”, “êµì í”
- “MessageSource”, “ë©ìì§”
- “messages.properties”
ìì¸ ì²ë¦¬ (resources/04-exception.md)
- “ì츔, “exception”, “ìë¬ ì²ë¦¬”
- “ExceptionHandler”, “ControllerAdvice”
- “ë¹ì¦ëì¤ ì츔, “ìì¤í ì츔
2. 리ìì¤ ë¡ë© ì ëµ
ë¨ì¼ í¤ìë ê°ì§
- User: “API ìëµ í¨í´ ìë ¤ì¤”
- â Read resources/01-api-response.md
ë³µí© ìì²
- User: “Spring Boot API íì¤ ì ì²´ ì¤ì í´ì¤”
- â Read resources/01-api-response.md
- â Read resources/02-logging.md
- â Read resources/03-i18n.md
- â Read resources/04-exception.md
ë¶ëª íí ìì²
- User: “Spring Boot ê°ë° ê°ì´ë”
- â 주ì 리ìì¤ ê°ì ì¤ëª í ì íì§ ì ì
Quick Reference
API ìëµ í¨í´
모ë APIë ApiResult<T> ëí¼ ì¬ì©:
// â
ì¬ë°ë¥¸ í¨í´
@PostMapping
public ResponseEntity<ApiResult<UserResponse>> createUser(...) {
return ResponseEntity.status(HttpStatus.CREATED)
.body(ApiResult.success(response, message));
}
// â ì못ë í¨í´
@GetMapping
public ResponseEntity<List<UserResponse>> getUsers() {
return ResponseEntity.ok(service.getAll());
}
ë¡ê¹ ë 벨 íì¤
| HTTP Method | Level | ì´ì |
|---|---|---|
| GET | DEBUG | ì¡°íë ë¹ë², ë ¸ì´ì¦ ê°ì |
| POST | INFO | ìì± ì¶ì íì |
| PUT/PATCH | INFO | ìì ì¶ì íì |
| DELETE | WARN | ìì ë ê°ì¬ ëì |
i18n ë©ìì§
// â
MessageSource ì¬ì©
messageSource.getMessage("user.created", null, locale);
// â íëì½ë©
return "ì¬ì©ìê° ìì±ëììµëë¤";
ìì
ìì 1: ì Controller ìì±
User: “ì¬ì©ì ê´ë¦¬ API ë§ë¤ì´ì¤”
- í¤ìë 매ì¹: “API” â API ìëµ + ë¡ê¹ + i18n
- Read resources/01-api-response.md
- Read resources/02-logging.md
- Read resources/03-i18n.md
- Controller ìì± (ApiResult í¨í´ ì ì©)
- ë¡ê¹ íì¤ ì ì©
- messages.properties ì ë°ì´í¸
ìì 2: ë¡ê¹ íì¤ ì ì©
User: “ë¡ê¹ ì´ë»ê² í´ì¼ í´?”
- í¤ìë 매ì¹: “ë¡ê¹ ” â ë¡ê¹ íì¤
- Read resources/02-logging.md
- HTTP ë©ìëë³ ë¡ê·¸ ë 벨 ìë´
- ë¡ê·¸ í¬ë§· ìì ì ê³µ
ìì 3: ìì¸ ì²ë¦¬ ì¤ì
User: “ìì¸ ì²ë¦¬ í¨í´ ìë ¤ì¤”
- í¤ìë 매ì¹: “ìì¸ ì²ë¦¬” â ìì¸ ì²ë¦¬
- Read resources/04-exception.md
- GlobalExceptionHandler í¨í´ ì ê³µ
- ë¹ì¦ëì¤/ìì¤í ìì¸ ë¶ë¦¬ ìë´
ì¤ì ìì¹
- ì¼ê´ì±: 모ë APIì ëì¼í ìëµ êµ¬ì¡°
- ì¶ì ì±: ë³ê²½ ìì ì ë¡ê·¸ë¡ ì¶ì ê°ë¥
- ë¤êµì´: ì¬ì©ì ë©ìì§ë íëì½ë© ê¸ì§
- ìì¸ ë¶ë¦¬: ë¹ì¦ëì¤ ìì¸ vs ìì¤í ìì¸
Technical Details
ìì¸í ì¤ì ë° ìì ë ê° ë¦¬ìì¤ íì¼ ì°¸ì¡°:
resources/01-api-response.md: ApiResult ëí¼ í¨í´resources/02-logging.md: HTTP ë©ìëë³ ë¡ê¹ íì¤resources/03-i18n.md: MessageSource ë¤êµì´ ì²ë¦¬resources/04-exception.md: GlobalExceptionHandler í¨í´