You've already forked golang-saas-starter-kit
mirror of
https://github.com/raseels-repos/golang-saas-starter-kit.git
synced 2025-08-10 22:41:25 +02:00
24 lines
540 B
Go
24 lines
540 B
Go
package handlers
|
|
|
|
import (
|
|
"context"
|
|
"net/http"
|
|
|
|
"geeks-accelerator/oss/saas-starter-kit/example-project/internal/platform/web"
|
|
)
|
|
|
|
// Health provides support for orchestration health checks.
|
|
type Health struct{}
|
|
|
|
// Check validates the service is ready and healthy to accept requests.
|
|
func (h *Health) Check(ctx context.Context, w http.ResponseWriter, r *http.Request, params map[string]string) error {
|
|
status := struct {
|
|
Status string `json:"status"`
|
|
}{
|
|
Status: "ok",
|
|
}
|
|
|
|
web.Respond(ctx, w, status, http.StatusOK)
|
|
return nil
|
|
}
|