owen200008 commented on PR #10380: URL: https://github.com/apache/dubbo/pull/10380#issuecomment-1200755308
> 还有一个问题是 ServiceBean 的 unexport 方法是谁调用的,理论上用户不会直接使用 ServiceBean 的,一般都是使用的 ReferenceConfig。如果 ServiceBean 的 unexport 是来自框架的调用,那么应该由外面的销毁管理器来统一清理。 这里有一个依赖关系是 ModuleModel => ConfigManager => ReferenceConfig,理论上是不应该由后级直接向前级直接发起调用的(一些特殊场景除外,但是要尽量减少这种场景),否则会很容易出现循环依赖。 我这边要做的就是service和ref的一个热加载的功能,service mesh里面控制面肯定也是需要这块的 1. 我原始是基于ServiceBean做export和unexport来实现的,我这边考虑改成用ServiceConfig去热加载服务,这样可以避开目前这个问题,我这边的实现这里应该是我用法问题 针对ServiceBean的代码增加我看了#8789 #8867 没有完全理解 1. 就是为什么不是加到自己成员的ModuleModel 2. ModuleModel => ConfigManager => ServiceConfig 理论上是不应该由后级直接向前级直接发起调用的,这个我非常同意,对用户使用的是ServiceConfig和ReferenceConfig,因此难免会有操作上设计到管理类的变更,更极端一些我可能不希望包含这些类,我只想包含定义变更的接口让对应管理层来实现 -- This is an automated message from the Apache Git Service. To respond to the message, please log on to GitHub and use the URL above to go to the specific comment. To unsubscribe, e-mail: [email protected] For queries about this service, please contact Infrastructure at: [email protected] --------------------------------------------------------------------- To unsubscribe, e-mail: [email protected] For additional commands, e-mail: [email protected]
