From b488bf0d601faf5202185b061b088dd68d5f3735 Mon Sep 17 00:00:00 2001 From: husharp Date: Mon, 1 Apr 2024 19:07:35 +0800 Subject: [PATCH] change api Signed-off-by: husharp --- pkg/cluster/api/pdapi.go | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/pkg/cluster/api/pdapi.go b/pkg/cluster/api/pdapi.go index a66384f78b..329946bacf 100644 --- a/pkg/cluster/api/pdapi.go +++ b/pkg/cluster/api/pdapi.go @@ -139,7 +139,7 @@ var ( pdStoresURI = "pd/api/v1/stores" pdStoresLimitURI = "pd/api/v1/stores/limit" pdRegionsCheckURI = "pd/api/v1/regions/check" - pdMSHealthPrefix = "api/v1/health" + tsoHealthPrefix = "tso/api/v1/health" ) func tryURLs(endpoints []string, f func(endpoint string) ([]byte, error)) ([]byte, error) { @@ -199,9 +199,9 @@ func (pc *PDClient) CheckHealth() error { return nil } -// CheckTSOHealth checks the health of TSO service +// 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", pdMSHealthPrefix) + servicePrefix := fmt.Sprintf("tso/%s", tsoHealthPrefix) endpoints := pc.getEndpoints(servicePrefix) if err := utils.Retry(func() error {