返回 Skill 列表
extension
分类: 开发与工程无需 API Key

ruoyi-cloud-plus-best-practices

统一的最佳实践技能,适用于RuoYi-Cloud-Plus后端工程。在设计、实现、重构或审查Java微服务代码时使用,当您需要一次性指导领域驱动设计(DDD)服务建模、基础服务/模块拆分(ruoyi-common + ruoyi-api + ruoyi-modules)以及项目编码规范时。

person作者: jakexiaohubgithub

RuoYi Cloud Plus Best Practices

Overview

Use this as the single entry skill for RuoYi-Cloud-Plus backend work. Apply it to keep architecture, base service boundaries, and code style consistent in one run.

Routing Rules

  1. Use DDD flow first when the task is a new domain capability, aggregate boundary change, or complex business refactor.
  2. Use basic-service flow first when the task is shared capability extraction or cross-service API design.
  3. Use code-convention flow first when the task is code review, PR cleanup, or style alignment.
  4. Run all three flows for medium-to-large feature delivery.

Unified Execution Flow

  1. Clarify scope and classify task type.
  • Task type: domain-design, base-capability, implementation, or review.
  • Map impacted modules: ruoyi-modules/*, ruoyi-api/*, ruoyi-common/*.
  1. Design architecture and boundaries.
  • Apply DDD package and dependency constraints.
  • Keep bounded context ownership clear.
  • Keep cross-service contracts in ruoyi-api.
  1. Place reusable capability correctly.
  • Put reusable infrastructure in ruoyi-common.
  • Put cross-service contracts in ruoyi-api.
  • Put provider and business orchestration in ruoyi-modules.
  1. Implement with project conventions.
  • Keep controller -> service -> mapper direction.
  • Keep BO/VO/Entity separation and conversion strategy.
  • Use required annotations for permission, logging, idempotency, transaction, and RPC.
  1. Run final quality checks.
  • Check dependency direction and module coupling.
  • Check API contract isolation from local entities.
  • Check formatting and naming alignment with project conventions.

Output Contract

When using this skill, always output:

  1. Scope classification and impacted modules.
  2. Architecture and dependency decisions.
  3. File-level implementation plan or change list.
  4. Convention and risk checklist.

References

  • DDD and layered design: references/ddd.md
  • Foundational service split: references/basic-service.md
  • Coding conventions and review checklist: references/code-convention.md