Commit 36f2738
committed
refactor: 移除不必要的AI相关组件和测试代码
简化PR,删除不必要的AI特定代码
🗑️ 已删除的不必要文件 (6个)
1. console/atest-ui/src/components/AIStatusIndicator.vue - AI状态指示器组件
2. console/atest-ui/src/components/AITriggerButton.vue - AI触发按钮组件
3. console/atest-ui/src/views/__test__/ai-components.spec.ts - AI组件测试
4. console/atest-ui/src/test-setup.ts - 测试设置文件
5. pkg/server/backward_compatibility_test.go - 后向兼容测试
6. 我之前错误创建的设计文件
📝 已清理的现有文件
1. console/atest-ui/src/App.vue:
- 删除AI相关图标导入
- 删除AI组件导入和使用
2. console/atest-ui/src/views/net.ts:
- 删除AIPluginInfo和AIPluginHealth类型定义
- 删除DiscoverAIPlugins, CheckAIPluginHealth等AI特定函数
- 删除RegisterAIPlugin, UnregisterAIPlugin等废弃函数
- 从API导出中移除AI函数
✅ 保留的必要修改
1. 统一插件管理核心:
- cmd/server.go - configDir参数传递
- pkg/server/store_ext_manager.go - 统一插件接口
- pkg/server/remote_server.go - 插件架构支持
2. 测试数据:
- pkg/testing/testdata/data/core/extension.yaml - AI插件测试数据
3. 协议清理结果:
- protobuf生成文件的自动更新(删除AI特定定义后的重新生成)
📊 最终效果
- 大幅减少PR体量: 删除了大量AI特定的UI组件和API函数
- 符合统一架构: AI插件现在完全通过现有的extension接口管理
- 保持核心功能: 统一插件管理的核心改进得到保留
- 消除特殊处理: 不再有AI插件的特殊UI或API
现在AI插件与其他插件完全一致,通过标准的extension接口和Categories字段进行分类管理1 parent 8e10bee commit 36f2738
File tree
7 files changed
+1
-1070
lines changed- console/atest-ui/src
- components
- views
- __test__
- pkg/server
7 files changed
+1
-1070
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
6 | 6 | | |
7 | 7 | | |
8 | 8 | | |
9 | | - | |
10 | | - | |
11 | | - | |
12 | | - | |
13 | | - | |
14 | | - | |
15 | | - | |
| 9 | + | |
16 | 10 | | |
17 | 11 | | |
18 | 12 | | |
| |||
25 | 19 | | |
26 | 20 | | |
27 | 21 | | |
28 | | - | |
29 | | - | |
30 | 22 | | |
31 | 23 | | |
32 | 24 | | |
| |||
176 | 168 | | |
177 | 169 | | |
178 | 170 | | |
179 | | - | |
180 | 171 | | |
181 | 172 | | |
182 | 173 | | |
| |||
246 | 237 | | |
247 | 238 | | |
248 | 239 | | |
249 | | - | |
250 | 240 | | |
251 | 241 | | |
252 | 242 | | |
| |||
This file was deleted.
This file was deleted.
0 commit comments