rangtao edited a comment on issue #2435: Summary of several issues of graceful shutdown URL: https://github.com/apache/incubator-dubbo/issues/2435#issuecomment-421541082 确实我看到2.6.3版本有相关修改,基本和我描述思路一致,有几个问题问题: 1.个人觉得思路有点偏差,最好的思路是将dubbo停机完全放到spring事件中,最好不要搞框架停机hook,额外增加复杂性,还做不好。比如2.6.3版本DubboBootstrap中registerShutHook,单纯注册dubbo的停机hook没太大的意义,还是需要开发注册spring的停机hook,本身hook执行是无序的,可能导致spring先关闭。在我们的使用场景中,基本都是加载dubbo相关xml启动的。 2. 为什么通过ApplicationContextInitializer注册的方式,需要考虑web.xml加载问题,而且也不针对web项目吧。为什么不在类似于ApplicationConfig类中直接implements ApplicaionListener,监听close事件,对于使用者来说不需要配置,更简单。 3.在destroyAll方法中,之前版本为了注册中心通知延迟,故意sleep了一段时间,2.6.3版本删除了相关代码逻辑,请问是怎么考虑的?
---------------------------------------------------------------- This is an automated message from the Apache Git Service. To respond to the message, please log on GitHub and use the URL above to go to the specific comment. For queries about this service, please contact Infrastructure at: [email protected] With regards, Apache Git Services --------------------------------------------------------------------- To unsubscribe, e-mail: [email protected] For additional commands, e-mail: [email protected]
