initial commit 2
This commit is contained in:
27
server/router/healthroute/controller.go
Normal file
27
server/router/healthroute/controller.go
Normal file
@@ -0,0 +1,27 @@
|
||||
package healthroute
|
||||
|
||||
import (
|
||||
"net/http"
|
||||
"sync"
|
||||
|
||||
"github.com/labstack/echo"
|
||||
)
|
||||
|
||||
var (
|
||||
instance *controller
|
||||
once sync.Once
|
||||
)
|
||||
|
||||
type controller struct {
|
||||
}
|
||||
|
||||
func controllerInstance() *controller {
|
||||
once.Do(func() {
|
||||
instance = &controller{}
|
||||
})
|
||||
return instance
|
||||
}
|
||||
|
||||
func (c *controller) handle(ctx echo.Context) error {
|
||||
return ctx.String(http.StatusOK, "OK")
|
||||
}
|
||||
Reference in New Issue
Block a user