Skip to content

Commit

Permalink
mcs: make compatible with cluster info page display (#7929)
Browse files Browse the repository at this point in the history
close #7928

Signed-off-by: lhy1024 <[email protected]>
  • Loading branch information
lhy1024 committed Mar 18, 2024
1 parent da3b6e3 commit 1331148
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions server/apiv2/handlers/micro_service.go
Original file line number Diff line number Diff line change
Expand Up @@ -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
}

Expand All @@ -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
}

Expand Down

0 comments on commit 1331148

Please sign in to comment.