更新RMDC系统的模块SKILL
This commit is contained in:
109
1-AgentSkills/developing-rmdc/SKILL.md
Normal file
109
1-AgentSkills/developing-rmdc/SKILL.md
Normal file
@@ -0,0 +1,109 @@
|
||||
---
|
||||
name: developing-rmdc
|
||||
description: "System-level guidance for RMDC platform development covering cross-module consistency, dependency rules, version compatibility, and global change workflows. Triggered when making changes affecting multiple modules, modifying shared contracts, or planning system-wide updates. Keywords: rmdc-core, rmdc-user-auth, rmdc-jenkins-branch-dac, rmdc-exchange-hub, rmdc-watchdog, rmdc-project-management, rmdc-work-procedure, rmdc-audit-log, cross-module, dependency."
|
||||
allowed-tools:
|
||||
- Read
|
||||
- Glob
|
||||
- Grep
|
||||
- Bash
|
||||
argument-hint: "$ARGUMENTS: <scope> [modules...] — scope: cross-module|dependency|version|release"
|
||||
---
|
||||
|
||||
# developing-rmdc
|
||||
|
||||
## 概述
|
||||
本 Skill 提供 RMDC 系统级开发指导,确保跨模块一致性、依赖管理与版本兼容。
|
||||
|
||||
## 动态上下文注入
|
||||
|
||||
### 查看模块结构
|
||||
!`ls -la internal/ 2>/dev/null || find . -maxdepth 2 -type d -name "rmdc-*"`
|
||||
|
||||
### 查看模块依赖
|
||||
!`grep -rn "import.*rmdc" --include="*.go" | grep -v "_test.go" | head -30`
|
||||
|
||||
---
|
||||
|
||||
## 模块依赖关系
|
||||
|
||||
```
|
||||
rmdc-core (API Gateway)
|
||||
├── rmdc-user-auth (认证/权限)
|
||||
│ ├── rmdc-work-procedure (工单)
|
||||
│ └── rmdc-jenkins-branch-dac (Jenkins权限数据)
|
||||
├── rmdc-jenkins-branch-dac (构建管理)
|
||||
│ └── rmdc-audit-log
|
||||
├── rmdc-exchange-hub (MQTT网关)
|
||||
│ └── rmdc-audit-log
|
||||
├── rmdc-watchdog (边缘代理)
|
||||
│ └── rmdc-project-management (一级授权)
|
||||
├── rmdc-project-management (项目管理)
|
||||
│ └── rmdc-audit-log
|
||||
├── rmdc-work-procedure (工单)
|
||||
│ └── rmdc-audit-log
|
||||
└── rmdc-audit-log (审计)
|
||||
```
|
||||
|
||||
---
|
||||
|
||||
## Plan(规划阶段)
|
||||
|
||||
### 跨模块变更检查
|
||||
| 变更类型 | 影响评估 |
|
||||
|:---|:---|
|
||||
| JWT Claims 变更 | 影响所有需鉴权模块 |
|
||||
| RBAC 角色变更 | 影响 user-auth + 所有权限检查点 |
|
||||
| 审计字段变更 | 影响所有写审计的模块 |
|
||||
| 工单流程变更 | 影响 user-auth + project-management |
|
||||
| MQTT Topic 变更 | 影响 exchange-hub + watchdog |
|
||||
|
||||
### 决策点
|
||||
- [ ] 识别所有受影响模块
|
||||
- [ ] 确定变更顺序(先依赖后被依赖)
|
||||
- [ ] 确定是否需要版本兼容期
|
||||
|
||||
---
|
||||
|
||||
## Verify(验证清单)
|
||||
|
||||
### 依赖一致性
|
||||
- [ ] 所有模块使用相同版本的 rmdc-common
|
||||
- [ ] JWT Claims 定义在所有模块一致
|
||||
- [ ] 错误码无冲突
|
||||
- [ ] 审计字段格式统一
|
||||
|
||||
### 接口兼容性
|
||||
- [ ] 内部 API 向后兼容
|
||||
- [ ] MQTT 消息格式兼容
|
||||
- [ ] 数据库 Schema 兼容
|
||||
|
||||
---
|
||||
|
||||
## Execute(执行步骤)
|
||||
|
||||
### 跨模块变更流程
|
||||
1. 创建变更计划文档
|
||||
2. 识别所有受影响模块
|
||||
3. 按依赖顺序更新(先 common,后业务)
|
||||
4. 在每个模块运行验证
|
||||
5. 集成测试
|
||||
6. 统一发布
|
||||
|
||||
---
|
||||
|
||||
## Pitfalls(常见坑)
|
||||
|
||||
1. **依赖版本不一致**:不同模块使用不同版本的 common 包。
|
||||
2. **JWT Claims 不同步**:一个模块新增字段,其他模块未解析。
|
||||
3. **发布顺序错误**:被依赖模块未先发布。
|
||||
4. **审计格式不统一**:不同模块的审计记录格式不同。
|
||||
5. **错误码冲突**:不同模块定义了相同的错误码。
|
||||
|
||||
---
|
||||
|
||||
## 相关文件
|
||||
| 用途 | 路径 |
|
||||
|:---|:---|
|
||||
| 模块依赖 | [reference/module-dependencies.md](reference/module-dependencies.md) |
|
||||
| 术语表 | [reference/terminology.md](reference/terminology.md) |
|
||||
| 版本兼容 | [reference/version-compatibility.md](reference/version-compatibility.md) |
|
||||
Reference in New Issue
Block a user