refactor: 更新ResourceManager和DiscoveryManager,简化资源注册流程,新增无状态资源刷新方法

This commit is contained in:
sean
2025-06-12 18:52:29 +08:00
parent 09e119d50f
commit cdd748d0dc
4 changed files with 432 additions and 22 deletions

View File

@ -26,9 +26,9 @@ class HelloCommand extends BasePouchCommand {
*/
async loadRoleRegistry () {
try {
// 使用新的ResourceManager架构初始化
await this.resourceManager.initializeWithNewArchitecture()
// 无状态资源刷新,确保能发现新创建的角色
await this.resourceManager.refreshResources()
// 获取所有角色相关的资源
const roleRegistry = {}