From 42fbffae2840c17bfc4cc3cb960264c3a14b2e3f Mon Sep 17 00:00:00 2001 From: Ryan Leung Date: Tue, 7 May 2024 18:24:28 +0800 Subject: [PATCH 1/2] fix the health check Signed-off-by: Ryan Leung --- pkg/cluster/api/pdapi.go | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/pkg/cluster/api/pdapi.go b/pkg/cluster/api/pdapi.go index b0e7f79595..c8c3ae82d6 100644 --- a/pkg/cluster/api/pdapi.go +++ b/pkg/cluster/api/pdapi.go @@ -202,8 +202,7 @@ func (pc *PDClient) CheckHealth() error { // CheckTSOHealth checks the health of TSO service(which is a Micro Service component of PD) func (pc *PDClient) CheckTSOHealth(retryOpt *utils.RetryOption) error { - servicePrefix := fmt.Sprintf("tso/%s", tsoHealthPrefix) - endpoints := pc.getEndpoints(servicePrefix) + endpoints := pc.getEndpoints(tsoHealthPrefix) if err := utils.Retry(func() error { var err error From 4cafd017b2d64d041f1825170267d403eaff9330 Mon Sep 17 00:00:00 2001 From: Ryan Leung Date: Wed, 8 May 2024 10:54:16 +0800 Subject: [PATCH 2/2] fix display Signed-off-by: Ryan Leung --- components/playground/playground.go | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/components/playground/playground.go b/components/playground/playground.go index 302ab8180b..d183a14de9 100644 --- a/components/playground/playground.go +++ b/components/playground/playground.go @@ -595,13 +595,13 @@ func (p *Playground) WalkInstances(fn func(componentID string, ins instance.Inst } } for _, ins := range p.tsos { - err := fn(spec.ComponentPD, ins) + err := fn(spec.ComponentTSO, ins) if err != nil { return err } } for _, ins := range p.schedulings { - err := fn(spec.ComponentPD, ins) + err := fn(spec.ComponentScheduling, ins) if err != nil { return err }