From 6d956023d7dd422ec2481944c5dbbdff4d610dc3 Mon Sep 17 00:00:00 2001 From: lhy1024 Date: Mon, 18 Mar 2024 15:47:14 +0800 Subject: [PATCH] mcs: make compatible with cluster info page display Signed-off-by: lhy1024 --- server/apiv2/handlers/micro_service.go | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/server/apiv2/handlers/micro_service.go b/server/apiv2/handlers/micro_service.go index 51668ab9ea8..209a4c95445 100644 --- a/server/apiv2/handlers/micro_service.go +++ b/server/apiv2/handlers/micro_service.go @@ -40,7 +40,7 @@ func RegisterMicroService(r *gin.RouterGroup) { func GetMembers(c *gin.Context) { svr := c.MustGet(middlewares.ServerContextKey).(*server.Server) if !svr.IsAPIServiceMode() { - c.AbortWithStatusJSON(http.StatusServiceUnavailable, "not support micro service") + c.AbortWithStatusJSON(http.StatusNotFound, "not support micro service") return } @@ -66,7 +66,7 @@ func GetMembers(c *gin.Context) { func GetPrimary(c *gin.Context) { svr := c.MustGet(middlewares.ServerContextKey).(*server.Server) if !svr.IsAPIServiceMode() { - c.AbortWithStatusJSON(http.StatusServiceUnavailable, "not support micro service") + c.AbortWithStatusJSON(http.StatusNotFound, "not support micro service") return }