mirror of
https://github.com/datarhei/core.git
synced 2025-10-04 15:42:57 +08:00
Remove /v1/about cluster API endpoint
This commit is contained in:
@@ -96,7 +96,6 @@ func NewAPI(config APIConfig) (API, error) {
|
||||
doc.GET("", echoSwagger.EchoWrapHandler(echoSwagger.InstanceName("ClusterAPI")))
|
||||
|
||||
a.router.GET("/", a.Version)
|
||||
a.router.GET("/v1/about", a.About)
|
||||
|
||||
a.router.GET("/v1/barrier/:name", a.Barrier)
|
||||
|
||||
@@ -155,24 +154,6 @@ func (a *api) Version(c echo.Context) error {
|
||||
return c.JSON(http.StatusOK, Version.String())
|
||||
}
|
||||
|
||||
// About returns info about the cluster
|
||||
// @Summary Cluster info
|
||||
// @Description Cluster info
|
||||
// @Tags v1.0.0
|
||||
// @ID cluster-1-about
|
||||
// @Produce json
|
||||
// @Success 200 {string} string
|
||||
// @Success 500 {object} Error
|
||||
// @Router /v1/about [get]
|
||||
func (a *api) About(c echo.Context) error {
|
||||
about, err := a.cluster.About()
|
||||
if err != nil {
|
||||
return Err(http.StatusInternalServerError, "", "%s", err.Error())
|
||||
}
|
||||
|
||||
return c.JSON(http.StatusOK, about)
|
||||
}
|
||||
|
||||
// Barrier returns if the barrier already has been passed
|
||||
// @Summary Has the barrier already has been passed
|
||||
// @Description Has the barrier already has been passed
|
||||
|
Reference in New Issue
Block a user