wonderslife/pdd-skills-v3/expert-springcloud

Claude Code and agent skill by wonderslife/pdd-skills-v3

Trust tier 3
  • community
Source check pending

Checking that the SKILL.md file is still in the repository.

Spring Cloud 微服务架构专家。当项目涉及服务注册与发现、配置中心、网关路由、熔断降级、链路追踪等微服务组件时自动触发。支持中文触发:微服务、网关配置、服务注册、熔断器、链路追踪。

Install

npx vskill@latest install wonderslife/pdd-skills-v3/expert-springcloud

SKILL.md

Spring Cloud 微服务专家 / Spring Cloud Microservice Expert

1. 技能概述 / Overview

🇨🇳 定位

为基于 Spring Cloud / Spring Cloud Alibaba 的微服务架构项目提供专家级指导,包括:服务治理、配置管理、API 网关、熔断降级、分布式事务、链路追踪等。

核心能力:

  • 服务注册与发现(Nacos/Eureka/Consul)
  • 配置中心管理(Nacos Config/Spring Cloud Config)
  • API 网关路由(Spring Cloud Gateway/Zuul)
  • 服务间调用(OpenFeign/RestTemplate)
  • 熔断与降级(Sentinel/Hystrix/Resilience4j)
  • 链路追踪(Sleuth + Zipkin/SkyWalking)
  • 分布式事务(Seata)
🇺🇸 Positioning

Provides expert-level guidance for Spring Cloud / Spring Cloud Alibaba microservice architecture projects, including: service governance, config management, API gateway, circuit breaking, distributed transactions, and distributed tracing.


2. 微服务架构规范 / Microservice Architecture Standards

🇨🇳
2.1 服务拆分原则
  • 按业务域拆分,每个服务对应一个限界上下文
  • 服务间禁止直接数据库访问,必须通过 API 调用
  • 共享代码通过公共模块(common)发布为 Maven 包
2.2 接口设计规范
  • 服务间调用统一使用 OpenFeign 客户端
  • Feign 接口定义放在独立的 xxx-api 模块中
  • 返回值统一使用 R<T> 包装类
  • 版本管理通过 URL 路径(/v1/, /v2/)实现
2.3 配置管理规范
  • 所有配置统一由 Nacos Config 管理
  • 配置文件按环境分离:xxx-dev.yml, xxx-prod.yml
  • 敏感配置(DB密码、密钥)必须加密存储
  • 配置变更必须记录变更日志
2.4 网关路由规范
  • 所有外部请求必须经过 Gateway 网关
  • 路由配置放在 Nacos Config 中,支持动态刷新
  • 网关层统一处理:鉴权、限流、日志、跨域
2.5 熔断与降级规范
  • 所有 Feign 调用必须配置 Sentinel 降级规则
  • 核心业务流必须有降级兜底方案
  • 慢调用/异常比例达到阈值时自动熔断
🇺🇸
2.1 Service Split Principles
  • Split by business domain, each service maps to a bounded context
  • Direct database access between services is forbidden; must use API calls
  • Shared code published as Maven packages through common modules
2.2 API Design Standards
  • Service-to-service calls use OpenFeign clients uniformly
  • Feign interface definitions in separate xxx-api modules
  • Return values wrapped uniformly in R<T> wrapper class
  • Version management through URL paths (/v1/, /v2/)
2.3 Config Management Standards
  • All configurations managed by Nacos Config centrally
  • Config files separated by environment: xxx-dev.yml, xxx-prod.yml
  • Sensitive configs (DB passwords, keys) must be encrypted
  • Config changes must have change logs

3. 常见问题模式 / Common Issue Patterns

🇨🇳
问题原因解决方案
Feign 调用 404服务名拼写错误或未注册到 Nacos检查 spring.application.name 和 Nacos 控制台
配置不生效未添加 @RefreshScope 或 Group 不匹配检查注解和 Nacos 配置分组
Gateway 路由失败路由谓词配置错误检查 predicates 和 filters 配置
分布式事务不回滚未配置 Seata 全局事务管理器添加 @GlobalTransactional 注解
链路追踪断裂异步线程未传递 Trace Context使用 TraceableExecutorService 包装线程池
🇺🇸
IssueCauseSolution
Feign call 404Service name typo or not registered in NacosCheck spring.application.name and Nacos console
Config not effectiveMissing @RefreshScope or Group mismatchCheck annotation and Nacos config group
Gateway route failureRoute predicate misconfiguredCheck predicates and filters configuration
Distributed TX no rollbackSeata global TX manager not configuredAdd @GlobalTransactional annotation
Trace chain brokenAsync threads not passing Trace ContextWrap thread pools with TraceableExecutorService

4. Guardrails

🇨🇳 必须遵守
  • [ ] 服务间调用必须使用 OpenFeign,禁止 RestTemplate 硬编码 URL
  • [ ] 所有 Feign 客户端必须配置降级 Fallback
  • [ ] 配置变更必须先在 dev 环境验证
  • [ ] 网关路由变更必须配合限流规则
  • [ ] 分布式事务方法必须标注 @GlobalTransactional

5. 版本历史 / Version History

版本 / Version日期 / Date变更内容 / Changes
1.02026-04-28初始版本 / Initial version

Security

  • Security scanPassed, 90 of 100Pattern checks on the skill's files.
  • Model reviewPassed

Quality evaluation

  • Task evaluationNot runNo evaluation yet. Run one in Skill Studio.

Source

Popularity

7-day trend score
0

Not refreshed yet.

Works with

Any agent vskill installs to: 56 targets in all. These 39 have a page on this site.

  • Claude Code
  • Cursor
  • GitHub Copilot
  • Windsurf
  • Codex
  • Gemini CLI
  • Cline
  • Amp
  • Roo Code
  • Goose
  • Continue
  • Kilo Code
  • Junie
  • Trae
  • OpenHands
  • Qwen Code
  • AI Agent
  • Tabnine Chat
  • Sourcegraph Cody
  • Amazon Q
  • Firebase Genkit
  • Sweep
  • Devin
  • Phind
  • Mentat
  • Claude Desktop
  • Aider
  • GPT Pilot
  • Plandex
  • bolt.new
  • v0
  • Replit Agent
  • Anse
  • TypingMind
  • BetterChatGPT
  • LibreChat
  • Warp AI
  • Pieces
  • Fig AI
Embed badge
vskill VERIFIED badge
[![vskill VERIFIED](https://verified-skill.com/api/v1/skills/wonderslife/pdd-skills-v3/expert-springcloud/badge)](https://verified-skill.com/skills/wonderslife/pdd-skills-v3/expert-springcloud)

Something wrong with this skill or its page? Tell us.