Revert "Revert "优化服务退出流程,增加中间件文档""

This reverts commit 64ed43b7ca.
This commit is contained in:
maxbad
2023-05-15 23:17:59 +08:00
parent 64ed43b7ca
commit 06292b603b
30 changed files with 335 additions and 97 deletions

View File

@@ -75,7 +75,7 @@ func (s *sAuthClient) Start(ctx context.Context) {
// Stop 停止服务
func (s *sAuthClient) Stop(ctx context.Context) {
if s.client != nil {
if s.client != nil && !s.client.IsStop() {
s.client.Stop()
g.Log().Debug(ctx, "AuthClient stop..")
}

View File

@@ -76,7 +76,7 @@ func (s *sCronClient) Start(ctx context.Context) {
// Stop 停止服务
func (s *sCronClient) Stop(ctx context.Context) {
if s.client != nil {
if s.client != nil && !s.client.IsStop() {
s.client.Stop()
g.Log().Debug(ctx, "CronClient stop..")
}