检查点:保存监听时序与中文目录修复,继续处理协调请求恢复
This commit is contained in:
1 parent
2c0d0e8eda
commit
76b4d94ca0
9 files changed
+310
-6
No files matched your search
@@ -84,6 +84,16 @@ func runApplication(ctx context.Context, cfg config.Config, path string) (bool,
|
||||
defer service.Close()
|
||||
errorsChannel := make(chan error, 1)
|
||||
go func() { errorsChannel <- service.HTTP.ListenAndServe() }()
|
||||
select {
|
||||
case <-ctx.Done():
|
||||
return false, nil
|
||||
case err := <-errorsChannel:
|
||||
if errors.Is(err, http.ErrServerClosed) {
|
||||
return false, nil
|
||||
}
|
||||
return false, err
|
||||
case <-service.HTTP.Listening():
|
||||
}
|
||||
if service.Renewal != nil {
|
||||
service.Renewal.Start(ctx)
|
||||
}
|
||||
|
||||
Reference in new issue
Block a user