humingcheng commented on code in PR #1499:
URL: 
https://github.com/apache/servicecomb-service-center/pull/1499#discussion_r1961152086


##########
server/health/health.go:
##########
@@ -19,12 +19,18 @@ package health
 
 import (
        "errors"
+       "fmt"
+       "time"
 
+       "github.com/apache/servicecomb-service-center/pkg/log"
        "github.com/apache/servicecomb-service-center/server/alarm"
+       "github.com/apache/servicecomb-service-center/syncer/config"
+       "github.com/apache/servicecomb-service-center/syncer/rpc"
 )
 
 var healthChecker Checker = &NullChecker{}
 var readinessChecker Checker = &DefaultHealthChecker{}
+var syncReadinessChecker Checker = &SyncReadinessChecker{startupTime: 
time.Now()}

Review Comment:
   起始时间点,应该是http对外提供服务的时间点,判断的条件是 !server.GetAPIServer().IsClose()



##########
server/health/health.go:
##########
@@ -65,5 +99,8 @@ func SetGlobalReadinessChecker(hc Checker) {
 }
 
 func GlobalReadinessChecker() Checker {
+       if config.GetConfig().Sync.EnableOnStart {

Review Comment:
   这两个checker都要运行,另一个不能丢。



-- 
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]

Reply via email to